@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=JetBrains+Mono:wght@400;600;700&display=swap');

:root {
  --accent: #7c3aed;
  --accent-hover: #6d28d9;
  --accent-light: rgba(124, 58, 237, 0.12);
  --accent2: #06b6d4;
  --danger: #f43f5e;
  --warn: #f59e0b;
  --success: #10b981;
  --purple: #8b5cf6;
  --radius: 14px;
  --radius-sm: 8px;
  --radius-xs: 6px;
  --font: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --transition: all .2s cubic-bezier(.4, 0, .2, 1);
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #090d16;
  --bg2: #0f172a;
  --bg3: #162035;
  --sidebar-bg: #0b111e;
  --border: rgba(255, 255, 255, 0.08);
  --border2: rgba(255, 255, 255, 0.14);
  --text: #f8fafc;
  --text2: #94a3b8;
  --text3: #64748b;
  --card: #0f172a;
  --card2: #131d33;
  --header: rgba(11, 17, 30, 0.88);
  --input-bg: #0b1220;
  --hover: rgba(255, 255, 255, 0.04);
  --skeleton: linear-gradient(90deg, #131d33 25%, #1e2c48 50%, #131d33 75%);
  --toast-bg: #131d33;
  --sidebar-text: #94a3b8;
  --sidebar-active: rgba(124, 58, 237, 0.22);
  --sidebar-hover: rgba(255, 255, 255, 0.05);
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.48);
  --pill-bg: rgba(124, 58, 237, 0.16);
  --pill-border: rgba(124, 58, 237, 0.28);
  --panel-soft: rgba(255, 255, 255, 0.03);
  --chart-grid-line: rgba(255, 255, 255, 0.06);
  --bar-track: #172238;
  --chart-dot-fill: var(--card);
}

[data-theme="light"] {
  color-scheme: light;
  --bg: #f8fafc;
  --bg2: #f1f5f9;
  --bg3: #e2e8f0;
  --sidebar-bg: #ffffff;
  --border: rgba(226, 232, 240, 0.85);
  --border2: rgba(203, 213, 225, 0.8);
  --text: #0f172a;
  --text2: #475569;
  --text3: #94a3b8;
  --card: #ffffff;
  --card2: #f8fafc;
  --header: rgba(255, 255, 255, 0.88);
  --input-bg: #ffffff;
  --hover: rgba(124, 58, 237, 0.04);
  --skeleton: linear-gradient(90deg, #e2e8f0 25%, #edf2f7 50%, #e2e8f0 75%);
  --toast-bg: #ffffff;
  --sidebar-text: #64748b;
  --sidebar-active: rgba(124, 58, 237, 0.10);
  --sidebar-hover: rgba(124, 58, 237, 0.05);
  --shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.06);
  --shadow-lg: 0 16px 36px -4px rgba(15, 23, 42, 0.08);
  --pill-bg: #f5f3ff;
  --pill-border: rgba(124, 58, 237, 0.12);
  --panel-soft: rgba(255, 255, 255, 0.7);
  --chart-grid-line: rgba(15, 23, 42, 0.05);
  --bar-track: #edf2f7;
  --chart-dot-fill: #ffffff;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html, body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-text-size-adjust: 100%;
  transition: background .3s, color .3s;
  -webkit-user-select: auto;
  user-select: auto;
}
input, textarea, select, [contenteditable="true"] { -webkit-user-select: text; user-select: text; }
input, textarea, select, button { color-scheme: inherit; }
input::placeholder, textarea::placeholder { color: var(--text3); opacity: 1; }
select option { background: var(--card); color: var(--text); }
input[type="date"]::-webkit-calendar-picker-indicator,
input[type="month"]::-webkit-calendar-picker-indicator { opacity: .75; cursor: pointer; }
[data-theme="dark"] input[type="date"]::-webkit-calendar-picker-indicator,
[data-theme="dark"] input[type="month"]::-webkit-calendar-picker-indicator { filter: invert(1) brightness(1.2); opacity: .85; }

[data-theme="dark"] input:-webkit-autofill,
[data-theme="dark"] input:-webkit-autofill:hover,
[data-theme="dark"] input:-webkit-autofill:focus,
[data-theme="dark"] textarea:-webkit-autofill,
[data-theme="dark"] select:-webkit-autofill {
  -webkit-text-fill-color: var(--text);
  caret-color: var(--text);
  box-shadow: 0 0 0 1000px var(--input-bg) inset;
  transition: background-color 9999s ease-out 0s;
}
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border2); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* ============================================================
   LUCIDE ICONS & ICON HELPERS
============================================================ */
.lucide,
svg.lucide,
svg[class*="lucide-"] {
  width: 18px;
  height: 18px;
  max-width: 18px;
  max-height: 18px;
  display: inline-block;
  vertical-align: middle;
  stroke-width: 2px;
  flex-shrink: 0;
}
.btn-icon, .card-ico, .title-ico, .banner-ico, .nav-ico, .timer-ico, .modal-ico, .hdr-date-ico, .eye-ico, .mini-ico, .abtn-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
  flex-shrink: 0;
  line-height: 1;
}
.title-ico,
.title-ico svg,
.title-ico .lucide,
.title-ico.lucide,
.btitle .title-ico,
.btitle .title-ico svg,
.btitle .title-ico .lucide,
.btitle > svg {
  width: 18px !important;
  height: 18px !important;
  min-width: 18px !important;
  min-height: 18px !important;
  max-width: 18px !important;
  max-height: 18px !important;
  color: var(--accent) !important;
  flex-shrink: 0 !important;
}
.btn-icon,
.btn-icon svg,
.btn-icon .lucide,
.btn-icon.lucide {
  width: 15px !important;
  height: 15px !important;
  min-width: 15px !important;
  min-height: 15px !important;
  max-width: 15px !important;
  max-height: 15px !important;
  flex-shrink: 0 !important;
}
.card-ico,
.card-ico svg,
.card-ico .lucide,
.card-ico.lucide {
  width: 16px !important;
  height: 16px !important;
  min-width: 16px !important;
  min-height: 16px !important;
  max-width: 16px !important;
  max-height: 16px !important;
  flex-shrink: 0 !important;
}
.modal-ico,
.modal-ico svg,
.modal-ico .lucide,
.modal-ico.lucide {
  width: 22px !important;
  height: 22px !important;
  min-width: 22px !important;
  min-height: 22px !important;
  max-width: 22px !important;
  max-height: 22px !important;
  flex-shrink: 0 !important;
}
.timer-ico,
.timer-ico svg,
.timer-ico .lucide,
.timer-ico.lucide {
  width: 14px !important;
  height: 14px !important;
  min-width: 14px !important;
  min-height: 14px !important;
  max-width: 14px !important;
  max-height: 14px !important;
  opacity: .85;
  flex-shrink: 0 !important;
}
.banner-ico,
.banner-ico svg,
.banner-ico .lucide,
.banner-ico.lucide {
  width: 18px !important;
  height: 18px !important;
  min-width: 18px !important;
  min-height: 18px !important;
  max-width: 18px !important;
  max-height: 18px !important;
  flex-shrink: 0 !important;
}
.hdr-date-ico,
.hdr-date-ico svg,
.hdr-date-ico .lucide,
.hdr-date-ico.lucide {
  width: 13px !important;
  height: 13px !important;
  color: var(--text3);
  flex-shrink: 0 !important;
}
.eye-ico,
.eye-ico svg,
.eye-ico .lucide,
.eye-ico.lucide {
  width: 17px !important;
  height: 17px !important;
  flex-shrink: 0 !important;
}
.mini-ico,
.mini-ico svg,
.mini-ico .lucide,
.mini-ico.lucide {
  width: 12px !important;
  height: 12px !important;
  flex-shrink: 0 !important;
}
.abtn-ico,
.abtn-ico svg,
.abtn-ico .lucide,
.abtn-ico.lucide,
.abtn svg,
.abtn .lucide {
  width: 17px !important;
  height: 17px !important;
  flex-shrink: 0 !important;
}

.ni, .nav-ico { width: 20px; height: 20px; display: inline-flex; align-items: center; justify-content: center; flex: 0 0 20px; }
.ni .lucide, .nav-ico .lucide { width: 18px; height: 18px; stroke: currentColor; }
.ui-icon { width: 18px; height: 18px; display: inline-flex; align-items: center; justify-content: center; flex: 0 0 18px; vertical-align: middle; }
.ui-icon .lucide, .ui-icon svg { width: 18px; height: 18px; }
.ui-icon.sm { width: 14px; height: 14px; flex-basis: 14px; }
.ui-icon.sm .lucide, .ui-icon.sm svg, .lucide.sm { width: 14px; height: 14px; }
.icon-label { display: inline-flex; align-items: center; gap: 8px; vertical-align: middle; }
.icon-label .lucide, .icon-label svg { width: 18px; height: 18px; flex-shrink: 0; }
.push-notif-btn .lucide { width: 16px; height: 16px; }
.fb-type .lucide, .fb-type svg { width: 12px; height: 12px; flex-shrink: 0; }
.badge .lucide, .badge svg { width: 12px; height: 12px; flex-shrink: 0; }
.tag .lucide, .tag svg { width: 12px; height: 12px; flex-shrink: 0; }
.scard-icon .lucide { width: 20px; height: 20px; }
.ip-icon .lucide { width: 28px; height: 28px; }

/* Theme toggle */
.theme-toggle { position: relative; width: 44px; height: 24px; flex-shrink: 0; }
.theme-toggle input { opacity: 0; width: 0; height: 0; }
.theme-slider { position: absolute; inset: 0; background: var(--bg3); border-radius: 20px; cursor: pointer; transition: var(--transition); border: 1px solid var(--border2); }
.theme-slider::before {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  left: 2px;
  top: 2px;
  background: var(--text2);
  border-radius: 50%;
  transition: transform .25s cubic-bezier(.22,1,.36,1), background .25s ease;
  box-shadow: 0 1px 3px rgba(0,0,0,0.25);
}
.theme-toggle input:checked + .theme-slider { background: var(--accent); border-color: var(--accent); }
.theme-toggle input:checked + .theme-slider::before { transform: translateX(20px); background: #ffffff; }

/* Language Switcher */
.flag { display: inline-flex; width: 30px; height: 20px; border-radius: 3px; overflow: hidden; flex-shrink: 0; }
.flag svg { width: 100%; height: 100%; display: block; }
.lsw { display: flex; align-items: center; gap: 4px; background: var(--bg3); border-radius: 20px; padding: 3px 6px; border: 1px solid var(--border); }
.lb { cursor: pointer; border: none; background: none; padding: 2px; border-radius: 4px; opacity: .55; transition: var(--transition); }
.lb.active { opacity: 1; box-shadow: 0 0 0 2px var(--accent); border-radius: 4px; }
.lsep { width: 1px; height: 18px; background: var(--border2); }

/* Shimmer Skeleton */
.skeleton { background: var(--skeleton); background-size: 200% 100%; animation: shimmer 1.5s infinite; border-radius: var(--radius-sm); }
@keyframes shimmer { 0%{background-position:200% 0} 100%{background-position:-200% 0} }
.sk-line { height: 14px; margin-bottom: 8px; }
.sk-line.short { width: 60%; }
.sk-line.long { width: 90%; }

/* Toast */
#toast-container { position: fixed; top: 18px; right: 18px; z-index: 99999; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.toast {
  background: var(--toast-bg);
  border: 1px solid var(--border2);
  border-radius: var(--radius);
  padding: 12px 16px;
  min-width: 270px;
  max-width: 360px;
  box-shadow: var(--shadow-lg);
  pointer-events: all;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  animation: slideIn .25s ease;
  font-size: 13px;
  backdrop-filter: blur(8px);
}
.toast.removing { animation: slideOut .25s ease forwards; }
.toast-icon { display: flex; align-items: center; justify-content: center; flex-shrink: 0; line-height: 1; margin-top: 1px; }
.toast-body { flex: 1; }
.toast-title { font-weight: 700; font-size: 13px; margin-bottom: 2px; }
.toast-msg { color: var(--text2); font-size: 12px; line-height: 1.4; }
.toast.success { border-left: 4px solid var(--success); }
.toast.success .toast-icon { color: var(--success); }
.toast.error { border-left: 4px solid var(--danger); }
.toast.error .toast-icon { color: var(--danger); }
.toast.warn { border-left: 4px solid var(--warn); }
.toast.warn .toast-icon { color: var(--warn); }
.toast.info { border-left: 4px solid var(--accent); }
.toast.info .toast-icon { color: var(--accent); }
@keyframes slideIn { from{transform:translateX(110%);opacity:0} to{transform:translateX(0);opacity:1} }
@keyframes slideOut { from{transform:translateX(0);opacity:1} to{transform:translateX(110%);opacity:0} }

/* ============================================================
   LOGIN PAGE
============================================================ */
#loginPage {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: var(--bg);
  padding: 16px;
  position: relative;
  overflow: hidden;
}
#loginPage::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% -10%, rgba(124, 58, 237, 0.14), transparent);
  pointer-events: none;
}
.lp-lang { position: fixed; top: 16px; right: 16px; z-index: 999; display: flex; align-items: center; gap: 8px; }
.logo-blk {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 420px;
  min-height: 240px;
  margin-bottom: 4px;
  position: relative;
  z-index: 1;
}
.logo-stack { position: relative; display: flex; align-items: center; justify-content: center; }
.logo-img-main {
  width: 380px;
  max-width: 100%;
  height: 220px;
  object-fit: contain;
  filter: drop-shadow(0 14px 36px rgba(124, 58, 237, 0.25));
  animation: logoFloat 3s ease-in-out infinite;
}
@keyframes logoFloat { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-6px)} }
.login-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 32px 28px;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--shadow-lg);
  position: relative;
  z-index: 1;
  animation: cardIn .4s cubic-bezier(.22,1,.36,1);
}
@keyframes cardIn { from{transform:translateY(24px);opacity:0} to{transform:translateY(0);opacity:1} }
.login-card h2 { text-align: center; font-size: 19px; font-weight: 800; margin-bottom: 6px; letter-spacing: -.3px; }
.login-card p { text-align: center; color: var(--text2); font-size: 13px; margin-bottom: 22px; }
.iw { position: relative; margin-bottom: 14px; }
.iw input {
  width: 100%;
  padding: 13px 44px 13px 14px;
  background: var(--input-bg);
  color: var(--text);
  border: 1.5px solid var(--border2);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: var(--font);
  outline: none;
  transition: var(--transition);
}
.iw input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.16); }
.eye { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); background: none; border: none; cursor: pointer; color: var(--text3); padding: 4px; display: inline-flex; align-items: center; justify-content: center; }
.eye:hover { color: var(--accent); }
.lbtn {
  width: 100%;
  padding: 13px;
  background: linear-gradient(135deg, var(--accent), #6366f1);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  margin-top: 6px;
  transition: var(--transition);
  font-family: var(--font);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 16px rgba(124, 58, 237, 0.28);
}
.lbtn:hover { transform: translateY(-1px); box-shadow: 0 8px 24px rgba(124, 58, 237, 0.38); }
.lbtn:active { transform: translateY(0); }
.lerr { color: var(--danger); font-size: 12px; text-align: center; margin-top: 10px; min-height: 16px; font-weight: 600; }

/* IP block */
#ipBlockPage { display: none; flex-direction: column; align-items: center; justify-content: center; min-height: 100vh; background: var(--bg); }
.ip-card { background: var(--card); border-radius: 18px; padding: 36px 28px; max-width: 440px; width: 100%; text-align: center; box-shadow: var(--shadow-lg); margin: 16px; border: 1px solid var(--border); }
.ip-icon { width: 56px; height: 56px; border-radius: 50%; background: rgba(244, 63, 94, 0.12); color: var(--danger); display: inline-flex; align-items: center; justify-content: center; margin-bottom: 14px; }
.ip-icon .lucide { width: 28px; height: 28px; }
.ip-card h2 { font-size: 20px; font-weight: 800; margin-bottom: 10px; }
.ip-card p { font-size: 13px; color: var(--text2); line-height: 1.6; }
.ip-val { display: inline-block; background: var(--bg3); border-radius: 8px; padding: 6px 14px; font-size: 13px; color: var(--text2); font-family: var(--mono); margin-top: 10px; border: 1px solid var(--border); }

/* ============================================================
   ADMIN DASHBOARD LAYOUT & SIDEBAR
============================================================ */
#adminPage, #employeePage { display: none; }
.layout { display: flex; min-height: 100vh; height: 100vh; overflow: hidden; }

.sidebar {
  width: 228px;
  background: var(--sidebar-bg);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  transition: transform .25s ease;
  border-right: 1px solid var(--border);
  box-shadow: 4px 0 24px rgba(0, 0, 0, 0.03);
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
  z-index: 150;
}
.sb-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 20px 18px 22px;
  border-bottom: 1px solid var(--border);
  background: var(--sidebar-bg);
}
.sb-logo-img { width: 34px; height: 34px; object-fit: contain; }
.sb-logo-txt { color: var(--text); font-size: 17px; font-weight: 800; letter-spacing: -.3px; }
.sb-logo-txt span {
  background: linear-gradient(135deg, var(--accent), #6366f1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.sb-nav { display: flex; flex-direction: column; gap: 6px; padding: 18px 10px; flex: 1; overflow-y: auto; }

.nbtn {
  padding: 10px 14px;
  background: transparent;
  color: var(--sidebar-text);
  border: none;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
  transition: var(--transition);
  font-family: var(--font);
  display: flex;
  align-items: center;
  gap: 11px;
  position: relative;
}
.nbtn:hover { background: var(--sidebar-hover); color: var(--text); }
.nbtn.active {
  background: var(--sidebar-active);
  color: var(--accent);
  font-weight: 700;
}
.nbtn.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 6px;
  bottom: 6px;
  width: 3px;
  border-radius: 4px;
  background: var(--accent);
}
.nbtn .ni { color: inherit; }


.sb-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 199; backdrop-filter: blur(3px); }
.sb-overlay.open { display: block; }
.hamburger { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 5px; flex-shrink: 0; }
.hamburger span { display: block; width: 22px; height: 2px; background: var(--text); border-radius: 2px; transition: var(--transition); }

.mcol { flex: 1; display: flex; flex-direction: column; min-width: 0; height: 100vh; min-height: 0; overflow: hidden; }

.tophdr {
  background: var(--header);
  padding: 16px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  gap: 14px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 120;
  backdrop-filter: blur(12px);
}
.tophdr h1 { color: var(--text); font-size: 17px; font-weight: 800; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; letter-spacing: -.2px; }
.hdr-r { display: flex; align-items: center; gap: 10px; flex-shrink: 0; flex-wrap: wrap; }
.hdr-date {
  color: var(--text2);
  font-size: 11.5px;
  white-space: nowrap;
  font-family: var(--mono);
  background: var(--bg3);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.xbtn {
  padding: 7px 14px;
  background: var(--bg3);
  color: var(--text2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition);
  font-family: var(--font);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.xbtn:hover { background: rgba(244, 63, 94, 0.12); color: var(--danger); border-color: rgba(244, 63, 94, 0.25); }

.pbody {
  flex: 1;
  min-height: 0;
  padding: 24px;
  overflow-y: auto;
  background: var(--bg);
}

/* ============================================================
   STAT CARDS (ADMIN)
============================================================ */
.scards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 22px;
}
.scard {
  background: var(--card);
  border-radius: var(--radius);
  padding: 16px 18px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
  transition: transform .22s ease, box-shadow .22s ease;
  animation: fadeUp .4s ease both;
}
.scard:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}
.scard-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.scard h4 {
  font-size: 11.5px;
  color: var(--text2);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
}
.snum {
  font-size: 26px;
  font-weight: 800;
  font-family: var(--mono);
  line-height: 1;
  letter-spacing: -.5px;
}
.scard-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--bg3);
  color: var(--accent);
  flex-shrink: 0;
}
.scard-icon .lucide { width: 19px; height: 19px; }

/* Status card tints */
.scard-work .scard-icon { background: rgba(16, 185, 129, 0.12); color: var(--success); }
.scard-work .snum { color: var(--success); }
.scard-late .scard-icon { background: rgba(245, 158, 11, 0.12); color: var(--warn); }
.scard-late .snum { color: var(--warn); }
.scard-absent .scard-icon { background: rgba(244, 63, 94, 0.12); color: var(--danger); }
.scard-absent .snum { color: var(--danger); }
.scard-leave .scard-icon { background: rgba(139, 92, 246, 0.12); color: var(--purple); }
.scard-leave .snum { color: var(--purple); }

@keyframes fadeUp { from{transform:translateY(12px);opacity:0} to{transform:translateY(0);opacity:1} }

/* Boxes, Cards & Content */
.box {
  background: var(--card);
  border-radius: var(--radius);
  padding: 22px 24px;
  box-shadow: var(--shadow);
  margin-bottom: 22px;
  border: 1px solid var(--border);
  animation: fadeUp .4s ease both;
}
.btitle {
  font-size: 15px;
  font-weight: 800;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text);
  letter-spacing: -.2px;
}

/* Tables */
.tbl-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}
.tbl { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.tbl th {
  background: var(--bg3);
  padding: 13px 16px;
  text-align: left;
  color: var(--text2);
  font-weight: 700;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
  font-size: 12px;
}
.tbl td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
  font-size: 12.5px;
  color: var(--text);
}
.tbl tr:last-child td { border-bottom: none; }
.tbl tr:hover td { background: var(--hover); }

/* Badges */
.badge {
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
  font-family: var(--mono);
}
.bg { background: rgba(16, 185, 129, 0.12); color: var(--success); border: 1px solid rgba(16, 185, 129, 0.25); }
.by { background: rgba(245, 158, 11, 0.12); color: var(--warn); border: 1px solid rgba(245, 158, 11, 0.25); }
.br { background: rgba(244, 63, 94, 0.12); color: var(--danger); border: 1px solid rgba(244, 63, 94, 0.25); }
.bgr { background: var(--bg3); color: var(--text3); border: 1px solid var(--border); }
.bafk { background: rgba(139, 92, 246, 0.12); color: var(--purple); border: 1px solid rgba(139, 92, 246, 0.25); }
.bauto { background: rgba(6, 182, 212, 0.12); color: var(--accent2); border: 1px solid rgba(6, 182, 212, 0.25); }

/* Forms & Inputs */
.frow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.frow input, .frow select, .sf input, .sf select {
  padding: 9px 12px;
  border: 1.5px solid var(--border2);
  border-radius: var(--radius-sm);
  font-size: 12.5px;
  background: var(--input-bg);
  color: var(--text);
  outline: none;
  transition: var(--transition);
  font-family: var(--font);
}
.frow input:focus, .frow select:focus, .sf input:focus, .sf select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.12);
}
.bb {
  padding: 9px 16px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition);
  font-family: var(--font);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.bb:hover { background: var(--accent-hover); transform: translateY(-1px); box-shadow: 0 6px 18px rgba(124, 58, 237, 0.25); }
.bg2 {
  padding: 9px 16px;
  background: var(--bg3);
  color: var(--text2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition);
  font-family: var(--font);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.bg2:hover { background: var(--hover); color: var(--text); }
.brd {
  padding: 6px 12px;
  background: rgba(244, 63, 94, 0.12);
  color: var(--danger);
  border: 1px solid rgba(244, 63, 94, 0.25);
  border-radius: var(--radius-sm);
  font-size: 11.5px;
  cursor: pointer;
  font-weight: 600;
  transition: var(--transition);
  font-family: var(--font);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.brd:hover { background: rgba(244, 63, 94, 0.22); }
.btn-export {
  padding: 8px 14px;
  background: rgba(6, 182, 212, 0.12);
  color: var(--accent2);
  border: 1px solid rgba(6, 182, 212, 0.25);
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.btn-export:hover { background: rgba(6, 182, 212, 0.20); transform: translateY(-1px); }

.drange { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.drange label { font-size: 11px; color: var(--text3); font-weight: 700; }
.drange input { padding: 7px 9px; border: 1.5px solid var(--border2); border-radius: var(--radius-sm); font-size: 12px; background: var(--input-bg); color: var(--text); }

.mst { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; margin-bottom: 16px; }
.ms { background: var(--bg3); border-radius: 10px; padding: 14px; border: 1px solid var(--border); }
.ms h5 { font-size: 11px; color: var(--text2); margin-bottom: 5px; text-transform: uppercase; letter-spacing: .4px; font-weight: 700; }
.ms .v { font-size: 20px; font-weight: 800; font-family: var(--mono); }

/* Dashboard Grids & Charts */
.dash-grid { display: grid; grid-template-columns: 1fr; gap: 20px; }
.dash-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; min-width: 0; box-shadow: var(--shadow); }
.dash-card h4 { font-size: 15px; color: var(--text); margin-bottom: 16px; font-weight: 800; }
.dash-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.dash-pill { background: var(--pill-bg); color: var(--accent); border: 1px solid var(--pill-border); border-radius: 8px; padding: 5px 10px; font-size: 11px; font-weight: 700; }
.dash-line-wrap { display: flex; flex-direction: column; gap: 16px; min-height: 220px; }
.dash-line-meta { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.dash-line-summary { display: flex; flex-direction: column; gap: 4px; }
.dash-line-label { font-size: 11px; color: var(--text3); text-transform: uppercase; letter-spacing: .4px; font-weight: 700; }
.dash-line-value { font-size: 32px; line-height: 1; font-weight: 800; color: var(--text); font-family: var(--mono); }
.dash-line-sub { font-size: 12px; color: var(--text2); }
.dash-line-stats { display: flex; gap: 10px; flex-wrap: wrap; }
.dash-mini-stat { min-width: 110px; background: var(--bg3); border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; }
.dash-mini-stat strong { display: block; font-size: 17px; color: var(--text); font-family: var(--mono); }
.dash-mini-stat span { display: block; margin-top: 4px; font-size: 11px; color: var(--text2); }
.dash-line-chart {
  position: relative;
  width: 100%;
  height: 190px;
  border-radius: 12px;
  background: linear-gradient(to bottom, rgba(124, 58, 237, 0.08), rgba(124, 58, 237, 0.01)), repeating-linear-gradient(to top, transparent 0, transparent 36px, var(--chart-grid-line) 37px);
  border: 1px solid var(--border);
  overflow: hidden;
}
.dash-line-chart svg { width: 100%; height: 100%; display: block; }
.dash-line-area { fill: url(#dashLineGradient); }
.dash-line-path { fill: none; stroke: var(--accent); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; }
.dash-line-dot { fill: var(--chart-dot-fill); stroke: var(--accent); stroke-width: 3; }
.dash-line-labels { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; margin-top: 4px; }
.dash-line-labels span { font-size: 11px; color: var(--text3); text-align: center; font-family: var(--mono); }

.dash-eff-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; max-height: 360px; overflow: auto; padding-right: 4px; }
.dash-eff-card { background: var(--bg3); border: 1px solid var(--border); border-radius: 10px; padding: 12px; min-width: 0; }
.dash-eff-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.dash-eff-name { font-size: 12.5px; font-weight: 800; color: var(--text); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-eff-score { font-size: 22px; font-weight: 900; color: var(--text); font-family: var(--mono); }

/* Settings form */
.sf { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }

/* Banners */
#afkBanner, #autoEndBanner, #breakBanner {
  display: none !important;
  position: fixed;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 11px 18px;
  font-size: 13px;
  font-weight: 700;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: var(--shadow);
  animation: slideDown .3s ease;
}
#employeePage #afkBanner.active,
#employeePage #autoEndBanner.active,
#employeePage #breakBanner.active {
  display: flex !important;
}
body.admin-view #afkBanner,
body.admin-view #autoEndBanner,
body.admin-view #breakBanner,
body.admin-view #installBanner {
  display: none !important;
}
#afkBanner { top: 0; background: linear-gradient(135deg, var(--danger), #be123c); color: #fff; }
#autoEndBanner { top: 0; background: linear-gradient(135deg, var(--success), #047857); color: #fff; }
#breakBanner { bottom: 0; background: linear-gradient(135deg, var(--warn), #b45309); color: #fff; }
@keyframes slideDown { from{transform:translateY(-100%)} to{transform:translateY(0)} }

#installBanner {
  display: none;
  position: fixed;
  bottom: 80px;
  right: 16px;
  z-index: 600;
  background: var(--card);
  border: 1px solid var(--border2);
  border-radius: var(--radius);
  padding: 14px 18px;
  box-shadow: var(--shadow-lg);
  max-width: 290px;
}
#installBanner p { font-size: 13px; color: var(--text); margin-bottom: 10px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.install-btns { display: flex; gap: 8px; }
.btn-install { padding: 8px 14px; background: var(--accent); color: #fff; border: none; border-radius: var(--radius-sm); font-size: 12px; font-weight: 700; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; font-family: var(--font); }
.btn-install-no { padding: 8px 12px; background: var(--bg3); color: var(--text2); border: none; border-radius: var(--radius-sm); font-size: 12px; cursor: pointer; font-family: var(--font); }

/* ============================================================
   EMPLOYEE ACCOUNT EXPERIENCE
============================================================ */
.ehdr {
  background: var(--header);
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 120;
  backdrop-filter: blur(12px);
}
.ehdr-left {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}
.ehdr-brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.ehdr-brand-name { color: var(--text); font-size: 16px; font-weight: 800; letter-spacing: -.2px; }
.ehdr-brand-name span { color: var(--accent); }

.ehdr-sep {
  width: 1px;
  height: 24px;
  background: var(--border);
  flex-shrink: 0;
}

.ehdr-user {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 4px 12px 4px 5px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 999px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  transition: all .2s ease;
}
.ehdr-user:hover {
  background: var(--card);
  border-color: var(--accent);
}

.ehdr-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent) 0%, #4338ca 100%);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .5px;
  flex-shrink: 0;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.12);
}
.ehdr-avatar-txt {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}
.ehdr-user-ico {
  width: 16px;
  height: 16px;
}
.ehdr-user-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
  justify-content: center;
}
.ehdr-user-name {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 180px;
}
.ehdr-user-sub {
  font-size: 11px;
  color: var(--text3);
  font-weight: 500;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 180px;
}

.ehdr-right {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  flex-shrink: 0;
}

/* Employee bottom nav - hidden by default on desktop */
.emp-bottom-nav {
  display: none !important;
}

.ebody {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  padding: 24px;
  background: var(--bg);
  min-height: calc(100vh - 73px);
  overflow-y: auto;
}
.ec {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  animation: fadeUp .4s ease both;
}
.ec h2 { font-size: 15px; font-weight: 800; margin-bottom: 16px; display: flex; align-items: center; gap: 8px; }
.efw { grid-column: 1 / -1; }

/* Status tags */
.tags { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.tag { padding: 5px 12px; border-radius: 20px; font-size: 11.5px; font-weight: 700; font-family: var(--mono); }
.tb { background: rgba(124, 58, 237, 0.12); color: var(--accent); border: 1px solid rgba(124, 58, 237, 0.22); }
.tg { background: var(--bg3); color: var(--text2); border: 1px solid var(--border); }
.to { background: rgba(245, 158, 11, 0.12); color: var(--warn); border: 1px solid rgba(245, 158, 11, 0.22); }
.ta { background: rgba(244, 63, 94, 0.12); color: var(--danger); border: 1px solid rgba(244, 63, 94, 0.22); }

/* Employee Action Buttons */
.abtns {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}
.abtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 8px;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  font-family: var(--font);
  box-shadow: 0 4px 14px rgba(0,0,0,.08);
}
.abtn .abtn-ico { display: inline-flex; align-items: center; justify-content: center; line-height: 1; }
.abtn .abtn-ico .lucide { width: 17px; height: 17px; }
.abtn:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(0,0,0,.18); }
.abtn:active:not(:disabled) { transform: translateY(1px); }
.abtn:disabled { opacity: .35; cursor: not-allowed; transform: none !important; box-shadow: none !important; }

.ast { background: linear-gradient(135deg, #10b981, #059669); color: #fff; }
.alu { background: linear-gradient(135deg, #f59e0b, #d97706); color: #fff; }
.apr { background: linear-gradient(135deg, #8b5cf6, #6d28d9); color: #fff; }
.aen { background: linear-gradient(135deg, #f43f5e, #e11d48); color: #fff; }

.aco {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  color: #fff;
  width: 100%;
  padding: 13px;
  margin-bottom: 16px;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font);
  box-shadow: 0 6px 18px rgba(99, 102, 241, .25);
  transition: var(--transition);
}
.aco:hover { transform: translateY(-1px); }

/* HUD Timers */
.tgrid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 14px;
}
.tb2 {
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  transition: var(--transition);
}
.tb2-head {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
  color: var(--text2);
}
.tb2 h4 {
  font-size: 11px;
  color: inherit;
  text-transform: uppercase;
  letter-spacing: .5px;
  font-weight: 700;
}
.tv {
  font-size: 26px;
  font-weight: 800;
  font-family: var(--mono);
  color: var(--text);
  line-height: 1.1;
  letter-spacing: .5px;
}

/* Prayer & Break Trackers */
.break-tracker {
  background: var(--bg3);
  border: 1.5px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  margin-top: 10px;
}
.bt-head { display: flex; align-items: center; gap: 7px; margin-bottom: 4px; }
.break-tracker h4 { font-size: 12px; font-weight: 700; color: var(--text); }
.break-bar-wrap { background: var(--bg2); border-radius: 20px; height: 8px; margin: 8px 0; overflow: hidden; border: 1px solid var(--border); }
.break-bar { height: 100%; border-radius: 20px; background: linear-gradient(90deg, var(--success), var(--warn)); transition: width .5s ease; }
.break-bar.over { background: linear-gradient(90deg, var(--warn), var(--danger)); }
.break-info { font-size: 11.5px; color: var(--text2); display: flex; justify-content: space-between; font-family: var(--mono); font-weight: 700; }

/* AFK Box */
.afk-box {
  background: rgba(244, 63, 94, 0.06);
  border: 1.5px solid rgba(244, 63, 94, 0.22);
  border-radius: 12px;
  padding: 14px;
  margin-top: 12px;
}
.afk-head { display: flex; align-items: center; gap: 7px; margin-bottom: 6px; }
.afk-box h4 { font-size: 12px; color: var(--danger); font-weight: 800; }
.afk-total { font-size: 24px; font-weight: 800; color: var(--danger); font-family: var(--mono); line-height: 1.1; }
.afk-count { font-size: 11.5px; color: var(--warn); margin-top: 4px; font-weight: 600; }
.afk-break-ok { font-size: 11.5px; color: var(--success); margin-top: 4px; font-weight: 700; display: inline-flex; align-items: center; gap: 5px; }

/* Employee Today Info Grid */
.igrid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ii { background: var(--bg3); border-radius: 10px; padding: 12px 14px; border: 1px solid var(--border); }
.ii h4 { font-size: 11px; color: var(--text2); margin-bottom: 4px; text-transform: uppercase; letter-spacing: .4px; font-weight: 700; }
.ii p { font-size: 14px; font-weight: 700; font-family: var(--mono); color: var(--text); }
.mhdr { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; gap: 8px; flex-wrap: wrap; }
.mhdr h2 { margin: 0; }
.mflt { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.mflt input { padding: 7px 10px; border: 1.5px solid var(--border2); border-radius: var(--radius-sm); font-size: 12px; background: var(--input-bg); color: var(--text); }

/* Face Recognition Widget */
#faceWidget {
  position: fixed;
  bottom: 18px;
  right: 18px;
  z-index: 500;
  background: var(--card);
  border-radius: 16px;
  padding: 12px;
  box-shadow: var(--shadow-lg);
  width: 190px;
  border: 1px solid var(--border);
  backdrop-filter: blur(8px);
}
#faceWidget .fw-title { color: var(--text); font-size: 11.5px; font-weight: 700; margin-bottom: 8px; display: flex; align-items: center; justify-content: space-between; }
#faceWidget video { width: 100%; border-radius: 10px; display: block; }
#faceWidget canvas { position: absolute; top: 12px; left: 12px; border-radius: 10px; pointer-events: none; }
.fw-status { display: flex; align-items: center; gap: 6px; margin-top: 6px; }
.fw-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.fw-dot.green { background: var(--success); box-shadow: 0 0 8px var(--success); }
.fw-dot.red { background: var(--danger); box-shadow: 0 0 8px var(--danger); animation: pulse 1s infinite; }
.fw-dot.yellow { background: var(--warn); box-shadow: 0 0 8px var(--warn); }
.fw-dot.gray { background: var(--text3); }
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:.5} }
.fw-txt { color: var(--text2); font-size: 11px; }
.fw-timer { color: var(--danger); font-size: 11px; font-weight: 700; margin-top: 4px; font-family: var(--mono); display: inline-flex; align-items: center; gap: 4px; }
.fw-afk { color: var(--text2); font-size: 10.5px; margin-top: 3px; font-family: var(--mono); }
.fw-video-wrap { position: relative; }
.fw-minimize { background: none; border: none; color: var(--text3); cursor: pointer; font-size: 14px; line-height: 1; padding: 2px; }
.fw-minimize:hover { color: var(--text); }
.fw-reg-btn {
  width: 100%;
  margin-top: 8px;
  padding: 7px;
  background: var(--pill-bg);
  color: var(--accent);
  border: 1px solid var(--pill-border);
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: var(--transition);
}
.fw-reg-btn:hover { background: rgba(124, 58, 237, 0.22); }

/* Face Reg Card */
.face-reg-box { background: var(--bg3); border-radius: var(--radius); padding: 14px; border: 1px solid var(--border); margin-bottom: 10px; }
.face-samples { display: flex; gap: 6px; margin-bottom: 8px; flex-wrap: wrap; }
.face-sample-dot { width: 32px; height: 32px; border-radius: 50%; background: var(--bg2); border: 2px solid var(--border2); display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; font-family: var(--mono); }
.face-sample-dot.done { background: rgba(16, 185, 129, 0.15); border-color: var(--success); color: var(--success); }
.liveness-indicator { display: flex; align-items: center; gap: 6px; font-size: 11px; color: var(--text2); margin-top: 6px; }
.liveness-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--text3); }
.liveness-dot.ok { background: var(--success); }
.liveness-dot.checking { background: var(--warn); animation: pulse 1s infinite; }

.face-control-card { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; flex-wrap: wrap; background: var(--bg3); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; }
.face-control-copy { min-width: 220px; flex: 1; }
.face-control-copy strong { display: block; color: var(--text); font-size: 13.5px; margin-bottom: 4px; }
.face-control-copy span { display: block; color: var(--text2); font-size: 12px; line-height: 1.5; }
.face-control-state { color: var(--text3); font-size: 11.5px; margin-top: 8px; }
.face-control-toggle { display: flex; align-items: center; gap: 10px; color: var(--text2); font-size: 12.5px; font-weight: 700; cursor: pointer; user-select: none; }

/* Push notif btn */
.push-notif-btn {
  width: 100%;
  padding: 11px;
  background: var(--pill-bg);
  color: var(--accent);
  border: 1px solid var(--pill-border);
  border-radius: var(--radius-sm);
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font);
  margin-bottom: 12px;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.push-notif-btn:hover { background: rgba(124, 58, 237, 0.22); }

/* Notification send form */
.notif-send-box {
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  margin-bottom: 24px;
}
.notif-send-box h4 {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 12px 0;
  letter-spacing: -.2px;
}
.notif-send-row {
  display: flex;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.notif-send-box select,
.notif-send-box input[type="text"],
.notif-send-box textarea {
  width: 100%;
  padding: 10px 14px;
  background: var(--input-bg);
  border: 1.5px solid var(--border2);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font);
  font-size: 13px;
  outline: none;
  transition: var(--transition);
  box-sizing: border-box;
}
.notif-send-box select:focus,
.notif-send-box input[type="text"]:focus,
.notif-send-box textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(132, 72, 255, 0.12);
}
.notif-send-box textarea {
  resize: vertical;
  min-height: 85px;
  line-height: 1.5;
}
.notif-send-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 12px;
}
.notif-send-actions .bb {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 20px;
  font-weight: 700;
  font-size: 13px;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

/* Notifications list */
.notif-badge { background: var(--danger); color: #fff; font-size: 10px; font-weight: 800; font-family: var(--mono); border-radius: 10px; padding: 1px 6px; margin-left: 6px; vertical-align: middle; }
.notif-item { display: flex; align-items: flex-start; gap: 10px; padding: 12px; border-bottom: 1px solid var(--border); transition: var(--transition); border-radius: var(--radius-sm); }
.notif-item.unread { background: rgba(124, 58, 237, 0.05); }
.notif-item:hover { background: var(--hover); }
.notif-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex-shrink: 0; margin-top: 5px; }
.notif-dot.read { background: var(--border2); }
.notif-body { flex: 1; }
.notif-title { font-size: 13px; font-weight: 700; margin-bottom: 2px; }
.notif-msg { font-size: 12px; color: var(--text2); line-height: 1.45; }
.notif-time { font-size: 10.5px; color: var(--text3); font-family: var(--mono); margin-top: 3px; }

/* Feedback styling */
.fb-item {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin-bottom: 10px;
  transition: var(--transition);
}
.fb-item:hover { border-color: var(--border2); box-shadow: var(--shadow-sm); }
.fb-item.new-item { border-left: 3px solid var(--accent); background: rgba(124, 58, 237, 0.03); }
.fb-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  flex-wrap: wrap;
  gap: 8px;
}
.fb-name { font-weight: 700; font-size: 13.5px; color: var(--text); }
.fb-type {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 999px;
}
.fb-type.complaint { background: rgba(239, 68, 68, 0.12); color: var(--danger); border: 1px solid rgba(239, 68, 68, 0.25); }
.fb-type.suggestion { background: rgba(245, 158, 11, 0.12); color: var(--warn); border: 1px solid rgba(245, 158, 11, 0.25); }
.fb-type.other { background: rgba(100, 116, 139, 0.12); color: var(--text2); border: 1px solid rgba(100, 116, 139, 0.25); }
.fb-date { font-size: 11px; color: var(--text3); font-family: var(--mono); }
.fb-msg { font-size: 13px; color: var(--text); line-height: 1.5; margin-bottom: 8px; white-space: pre-wrap; }
.fb-replied {
  margin-top: 8px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  background: rgba(16, 185, 129, 0.08);
  border: 1px solid rgba(16, 185, 129, 0.2);
  color: var(--success);
  font-size: 12px;
  font-weight: 600;
}
.fb-reply-area { margin-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.fb-reply-area textarea {
  width: 100%;
  padding: 8px 12px;
  background: var(--input-bg);
  border: 1px solid var(--border2);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font);
  font-size: 12.5px;
  resize: vertical;
  min-height: 60px;
  outline: none;
}
.fb-reply-area textarea:focus { border-color: var(--accent); }

/* Modals */
.ov {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 16px;
  backdrop-filter: blur(8px);
  animation: fadein .2s ease;
}
@keyframes fadein { from{opacity:0} to{opacity:1} }
.modal {
  background: var(--card);
  border-radius: 20px;
  padding: 30px 26px;
  max-width: 480px;
  width: 100%;
  text-align: center;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border2);
  animation: modalIn .3s cubic-bezier(.22,1,.36,1);
}
.modal.modal-wide { max-width: 920px; text-align: left; }
@keyframes modalIn { from{transform:scale(.92) translateY(20px);opacity:0} to{transform:scale(1) translateY(0);opacity:1} }
.modal p { font-size: 13px; color: var(--text2); line-height: 1.6; margin-bottom: 16px; }
.modal h3 { font-size: 17px; font-weight: 800; margin-bottom: 12px; letter-spacing: -.2px; }
.mbtns { display: flex; gap: 10px; justify-content: center; }
.mok {
  padding: 11px 26px;
  background: linear-gradient(135deg, var(--success), #059669);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font);
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.mok:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(16, 185, 129, 0.28); }
.mno {
  padding: 11px 26px;
  background: linear-gradient(135deg, var(--danger), #e11d48);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font);
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.mno:hover { transform: translateY(-1px); }
.msingle {
  padding: 11px 40px;
  background: linear-gradient(135deg, var(--accent), #6366f1);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font);
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.msingle:hover { transform: translateY(-1px); }
.hidden { display: none !important; }
.afk-modal-border { border: 2px solid var(--danger) !important; }
.countdown { font-size: 38px; font-weight: 900; color: var(--danger); margin: 12px 0; font-family: var(--mono); }



/* ============================================================
   RESPONSIVE DESIGN
============================================================ */
@media(max-width: 992px){
  .scards { grid-template-columns: repeat(2, 1fr); }
  .mst { grid-template-columns: repeat(3, 1fr); }
  .dash-grid { grid-template-columns: 1fr; }
  .dash-eff-grid { grid-template-columns: 1fr; }
}
@media(max-width: 768px){
  /* Employee bottom nav */
  .emp-bottom-nav {
    display: flex !important;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 300;
    background: var(--header);
    border-top: 1px solid var(--border);
    padding: 8px 0 10px;
    backdrop-filter: blur(12px);
  }
  .ebn-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    background: none;
    border: none;
    color: var(--text3);
    font-size: 10.5px;
    font-family: var(--font);
    cursor: pointer;
    padding: 4px 2px;
    transition: var(--transition);
  }
  .ebn-btn .nav-ico { width: 22px; height: 22px; }
  .ebn-btn .nav-ico .lucide { width: 20px; height: 20px; }
  .ebn-btn.active { color: var(--accent); font-weight: 700; }
  #employeePage { padding-bottom: 74px; }

  /* Mobile header */
  .ehdr { padding: 10px 12px; gap: 8px; }
  .ehdr-left { gap: 8px; }
  .ehdr-sep { height: 20px; }
  .ehdr-user { padding: 3px 8px 3px 4px; gap: 7px; }
  .ehdr-avatar { width: 28px; height: 28px; font-size: 11px; }
  .ehdr-user-name { font-size: 12.5px; max-width: 120px; }
  .ehdr-user-sub { font-size: 10px; max-width: 120px; }
  .ehdr > div:last-child { gap: 6px; }
  .ehdr > div:last-child .xbtn:not(#empExit) { display: none; }
  .ehdr #empDate { display: none; }
  .ehdr #empExitTxt { display: none; }

  /* Employee body */
  .ebody { grid-template-columns: 1fr; gap: 14px; padding: 14px 10px; }
  .efw { grid-column: 1; }

  /* Timers */
  .tgrid { grid-template-columns: 1fr; gap: 8px; }
  .tv { font-size: 26px; }

  /* Action buttons */
  .abtns { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .abtn { padding: 14px 6px; font-size: 13px; }

  /* Admin sidebar on mobile */
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; z-index: 200; width: 240px; transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .hamburger { display: flex; }
  .tophdr { padding: 10px 12px; gap: 8px; }
  .tophdr h1 { font-size: 14px; }
  .hdr-date { display: none; }
  .hdr-r { gap: 6px; }
  .hdr-r #admExitTxt { display: none; }
  .pbody { padding: 14px 10px; }
  .scards { grid-template-columns: 1fr 1fr; gap: 10px; }
  .snum { font-size: 24px; }
  .mst { grid-template-columns: 1fr 1fr; gap: 8px; }
  .frow { flex-direction: column; align-items: stretch; }
  .frow input, .frow select { width: 100%; }
  .drange { flex-wrap: wrap; }
  .drange input { flex: 1; min-width: 120px; }
  .box { padding: 16px 14px; }
  .notif-send-row { flex-direction: column; }
  #faceWidget { width: 155px; bottom: 10px; right: 10px; }
}

@media(max-width: 480px){
  .ehdr-brand-name { display: none; }
  .ehdr-user-sub { display: none; }
  .ehdr-user-name { max-width: 105px; font-size: 12px; }
  .scards { grid-template-columns: 1fr 1fr; gap: 8px; }
  .scard { padding: 12px 12px; }
  .scard h4 { font-size: 10px; }
  .snum { font-size: 20px; }
  .scard-icon { width: 30px; height: 30px; }
  .scard-icon .lucide { width: 16px; height: 16px; }
  .logo-blk { max-width: 320px; min-height: 180px; }
  .logo-img-main { width: 300px; height: 160px; }
  .igrid { grid-template-columns: 1fr; }
  .abtns { grid-template-columns: 1fr 1fr; }
}

/* Role Badges */
.role-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.2px;
}
.role-badge.role-manager {
  background: rgba(132, 72, 255, 0.12);
  color: #8448ff;
  border: 1px solid rgba(132, 72, 255, 0.24);
}
.role-badge.role-senior {
  background: rgba(99, 102, 241, 0.12);
  color: #6366f1;
  border: 1px solid rgba(99, 102, 241, 0.24);
}
.role-badge.role-operator {
  background: rgba(16, 185, 129, 0.12);
  color: #059669;
  border: 1px solid rgba(16, 185, 129, 0.24);
}
.role-badge.role-sales_operator {
  background: rgba(8, 145, 178, 0.12);
  color: #0891b2;
  border: 1px solid rgba(8, 145, 178, 0.24);
}
.role-badge.role-intern {
  background: rgba(245, 158, 11, 0.12);
  color: #d97706;
  border: 1px solid rgba(245, 158, 11, 0.24);
}
.role-badge.role-junior {
  background: rgba(2, 132, 199, 0.12);
  color: #0284c7;
  border: 1px solid rgba(2, 132, 199, 0.24);
}

/* OnlinePBX Styles */
.scard-blue .scard-icon { background: rgba(30, 179, 228, 0.12); color: var(--accent); }
.scard-blue .snum { color: var(--accent); }

.pbx-preset-btn.active {
  background: var(--accent) !important;
  color: #fff !important;
  border-color: var(--accent) !important;
}
.pbx-preset-btn {
  transition: all .2s ease;
}


