:root{--bg:#f3f6fb;--surface:#fff;--text:#172033;--muted:#748096;--primary:#286ee6;--line:#e6ebf2}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--text);font-family:"Microsoft YaHei","PingFang SC",sans-serif;font-size:14px}button,input,textarea,select{font:inherit}button{cursor:pointer;border:1px solid var(--line);border-radius:8px;padding:10px 15px;background:white;color:var(--text)}button:hover{background:#edf3ff}button:disabled{cursor:not-allowed;opacity:.55}button:focus-visible,a:focus-visible{outline:3px solid #90b6ff;outline-offset:2px}.primary{background:var(--primary);color:white;border-color:var(--primary)}.primary:hover{background:#205dc4}.hidden{display:none!important}.logo{width:43px;height:43px;border-radius:12px;background:linear-gradient(140deg,#286ee6,#179c93);color:white;font-size:24px;font-weight:bold;display:grid;place-items:center}.layout{display:grid;grid-template-columns:235px minmax(0,1fr);min-height:100vh}aside{position:sticky;top:0;height:100vh;background:white;border-right:1px solid var(--line);padding:27px 18px;display:flex;flex-direction:column}.brand{display:flex;align-items:center;gap:12px;padding:0 6px 27px;border-bottom:1px solid var(--line)}.brand strong{font-size:19px}.brand small{display:block;margin-top:5px;color:var(--muted);letter-spacing:2px;font-size:10px}.nav-caption{font-size:11px;color:var(--muted);margin:26px 12px 10px}nav button{display:flex;gap:13px;width:100%;border:0;background:transparent;text-align:left;margin:4px 0;padding:13px;color:#68758c}nav button.active{background:#edf3ff;color:#286ee6;font-weight:bold}.sidebar-bottom{margin-top:auto;padding:16px 8px;color:#59677c;font-size:12px}.status-dot{display:inline-block;width:7px;height:7px;background:#1aa889;border-radius:50%;margin-right:5px}main{padding:32px 38px 18px;max-width:1600px;width:100%;margin:auto}header{display:flex;justify-content:space-between;align-items:center;margin-bottom:25px}h1{font-size:27px;margin:7px 0}h2{font-size:19px;margin:0}h3{font-size:16px}.eyebrow{font-size:10px;letter-spacing:2px;color:var(--muted);margin:0}.header-actions{display:flex;gap:10px}.demo-banner{display:flex;gap:14px;align-items:center;padding:13px 17px;background:#fff8e9;border:1px solid #f2e3bd;border-radius:9px;color:#8a6829;font-size:12px;margin-bottom:23px}.hero{padding:29px;border-radius:13px;background:linear-gradient(110deg,#e4edff,#edf6f5);display:flex;justify-content:space-between;align-items:center;margin-bottom:22px}.hero h2{font-size:25px;margin:0 0 10px}.hero p{color:#637791;margin:0;line-height:1.8}.hero .hero-label{font-size:12px;letter-spacing:2px;color:#5c7ba6}.stats{display:grid;grid-template-columns:repeat(4,1fr);gap:16px;margin-bottom:25px}.stat,.panel,.workflow{border:1px solid var(--line);background:white;border-radius:11px;padding:22px}.stat span{color:var(--muted);font-size:12px}.stat strong{display:block;font-size:29px;margin-top:13px}.section-head{display:flex;justify-content:space-between;align-items:center;margin:22px 0 15px}.section-head p{margin:6px 0;color:var(--muted);font-size:12px}.home-grid{display:grid;grid-template-columns:minmax(0,2fr) minmax(260px,1fr);gap:20px}.task-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}.task-card{background:white;border:1px solid var(--line);border-radius:11px;padding:20px;display:flex;flex-direction:column;min-height:205px}.task-card h3{margin:15px 0 9px;line-height:1.6;overflow-wrap:anywhere}.task-card p{color:var(--muted);line-height:1.7;margin:0 0 20px;flex:1;white-space:pre-wrap;overflow-wrap:anywhere}.card-meta{display:flex;justify-content:space-between;align-items:center}.badge{padding:4px 9px;border-radius:5px;font-size:11px;background:#eef2f7;color:#617087}.badge.progress{background:#edf3ff;color:#286ee6}.badge.done{background:#e7f7f0;color:#168461}.priority{font-size:11px;color:#c07c30}.card-foot{border-top:1px solid var(--line);padding-top:13px;display:flex;justify-content:space-between;align-items:center;color:var(--muted);font-size:11px}.card-foot button{padding:5px 9px;font-size:12px}.toolbar{display:flex;gap:10px;flex-wrap:wrap;margin:20px 0}.toolbar input{flex:1;min-width:190px}.muted{color:var(--muted);line-height:1.8}.small{font-size:12px}.list-row{display:flex;gap:12px;align-items:center;padding:15px 0;border-bottom:1px solid var(--line)}.list-row:last-child{border:0}.list-row div{flex:1}.list-row strong{display:block;margin-bottom:5px}.list-row button{font-size:12px}.quick-link{display:block;width:100%;text-align:left;margin-top:12px;padding:16px}.workflow-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:18px}.workflow p{line-height:1.8;color:var(--muted);min-height:45px}.workflow .badge{float:right}.empty{text-align:center;padding:55px 20px;background:white;border:1px dashed #d6dfeb;border-radius:12px;color:var(--muted)}.empty h2{color:var(--text);margin-bottom:12px}footer{display:flex;justify-content:space-between;margin-top:40px;font-size:11px;color:#8792a5;padding:15px 0;border-top:1px solid var(--line)}input,textarea,select{width:100%;padding:11px;border:1px solid #dce3ee;border-radius:7px;background:white;color:var(--text)}input:focus,textarea:focus,select:focus{outline:2px solid #abc8ff;border-color:#abc8ff}label{display:block;font-size:12px;color:#56647b;margin:16px 0 8px}label input,label textarea,label select{margin-top:8px}.login{min-height:100vh;display:grid;place-items:center;padding:20px;background:radial-gradient(ellipse at 20% 20%,#dce8ff,transparent 55%),var(--bg)}.login-card{width:min(440px,100%);padding:36px;background:white;border:1px solid var(--line);border-radius:16px;box-shadow:0 20px 65px #263d5f12}.login-card .eyebrow{margin:23px 0 12px}.login-card h1{font-size:24px}.login-card .primary{width:100%;margin-top:7px}dialog{width:min(620px,calc(100% - 28px));border:1px solid var(--line);border-radius:14px;padding:27px;max-height:90vh}dialog::backdrop{background:#12223b66}.dialog-head{display:flex;justify-content:space-between;align-items:center}.dialog-head h2{margin-top:8px}.dialog-head button{font-size:20px;border:0}.form-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}.dialog-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:22px}#noteHistory{max-height:180px;overflow:auto}.note{border-left:2px solid #b7cfff;padding:8px 12px;margin:12px 0;background:#f6f9ff;white-space:pre-wrap;overflow-wrap:anywhere}.note small{display:block;color:var(--muted);margin-top:5px}#loginError,#taskError{color:#b83b32;font-size:12px}#toast{position:fixed;bottom:25px;left:50%;transform:translateX(-50%);background:#20334f;color:white;padding:13px 22px;border-radius:9px;z-index:20}@media(max-width:1100px){.task-grid{grid-template-columns:repeat(2,1fr)}main{padding:25px}.home-grid{grid-template-columns:1fr}}@media(max-width:700px){.layout{grid-template-columns:1fr}aside{position:static;height:auto;padding:15px}.brand{padding-bottom:12px}.nav-caption,.sidebar-bottom{display:none}nav{display:flex;flex-wrap:wrap}nav button{width:auto;padding:10px;font-size:12px}main{padding:18px}header{align-items:flex-start;gap:10px}.header-actions{flex-direction:column}h1{font-size:22px}.stats{grid-template-columns:repeat(2,1fr)}.task-grid,.workflow-grid{grid-template-columns:1fr}.hero{padding:22px}.hero-label{display:none}.demo-banner{align-items:flex-start;flex-direction:column;gap:5px}.form-grid{grid-template-columns:1fr}footer span{display:none}}

/* KZONE_LOGIN_REGISTRATION_V1 */
#login.login {
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  grid-template-rows: 1fr auto;
  align-items: stretch;
  justify-items: center;
  gap: 24px;
  padding: 32px 20px max(12px, env(safe-area-inset-bottom));
}
#login .login-card { align-self: center; }
#login .login-card h1 { line-height: 1.4; }
#login .login-card label { color: #45566f; font-size: 13px; }
#login .login-card input { min-height: 44px; }
#login .login-card input::placeholder { color: #778397; }
#login .login-card .primary { min-height: 44px; }
#login .login-registration {
  display: block;
  width: 100%;
  margin: 0;
  padding: 6px 0;
  border: 0;
  text-align: center;
  color: #52627a;
  font-size: 12px;
  line-height: 1.6;
  align-self: end;
}
#login .login-registration a { display: inline-block; padding: 4px 8px; color: inherit; text-decoration: none; }
#login .login-registration a:hover { text-decoration: underline; color: #205fc5; }
#login .login-registration a:focus-visible { outline: 2px solid #286ee6; outline-offset: 3px; border-radius: 4px; }
/* Older gateway versions also append a footer after the full-height login.
   The login now owns its visible footer; suppress only that duplicate. */
#login:not(.hidden) ~ footer { display: none; }
@media (max-width: 480px) {
  #login.login { gap: 20px; padding: 20px 16px max(12px, env(safe-area-inset-bottom)); }
  #login .login-card { padding: 28px 24px; }
  #login .login-card h1 { font-size: 23px; }
}
@media (max-height: 600px) {
  #login.login { gap: 16px; padding-top: 16px; }
  #login .login-card { padding: 24px; }
}
