:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --blue: #0878bd;
  --blue-dark: #04578f;
  --blue-soft: #eaf5fc;
  --green: #15966f;
  --ink: #10243a;
  --muted: #66788a;
  --line: #dce7ef;
  --surface: #ffffff;
  --bg: #eef5f9;
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); min-height: 100dvh; }
button { font: inherit; }
button:focus-visible { outline: 3px solid #70bee9; outline-offset: 3px; }
.app-shell { width: min(100%, 430px); min-height: 100dvh; margin: 0 auto; background: var(--surface); position: relative; overflow: hidden; box-shadow: 0 0 50px rgba(13, 56, 83, .12); }
.login-screen { min-height: 100dvh; display: flex; flex-direction: column; padding: max(34px, env(safe-area-inset-top)) 26px max(28px, env(safe-area-inset-bottom)); background: linear-gradient(155deg, #f8fcff 0 57%, #e7f5fc 100%); }
.brand-card { display: flex; align-items: center; gap: 16px; }
.brand-logo { width: 76px; height: 76px; border-radius: 21px; object-fit: cover; box-shadow: 0 10px 25px rgba(8,120,189,.16); }
.brand-card h1 { margin: 1px 0 0; font-size: 2rem; letter-spacing: -.04em; }
.eyebrow { margin: 0; font-size: .75rem; font-weight: 800; letter-spacing: .16em; color: var(--blue); }
.welcome { margin: 64px 0 26px; }
.demo-pill { display: inline-flex; padding: 7px 11px; border-radius: 999px; background: var(--blue-soft); color: var(--blue-dark); font-size: .72rem; font-weight: 800; letter-spacing: .09em; }
.welcome h2 { margin: 20px 0 10px; font-size: clamp(2.15rem, 11vw, 3.15rem); line-height: .98; letter-spacing: -.055em; }
.welcome p { margin: 0; color: var(--muted); line-height: 1.55; font-size: 1rem; }
.login-form { display: grid; gap: 14px; }
.login-form label { display: grid; gap: 7px; color: #30485d; font-size: .82rem; font-weight: 800; }
.login-form input { width: 100%; min-height: 52px; padding: 0 15px; border: 1px solid #cfdce5; border-radius: 14px; background: white; color: var(--ink); font: inherit; font-size: 1rem; }
.login-form input:focus { outline: 3px solid #d4eefb; border-color: var(--blue); }
.form-message { min-height: 18px; margin: -2px 2px 0; color: #b43f2d; font-size: .82rem; line-height: 1.4; }
.primary,.install-button,.secondary,.clock-button { width: 100%; min-height: 54px; border-radius: 16px; font-weight: 800; border: 0; cursor: pointer; }
.primary,.clock-button { background: linear-gradient(135deg, var(--blue), #0a98d8); color: white; box-shadow: 0 12px 25px rgba(8,120,189,.22); }
.install-button { margin-top: 12px; background: var(--ink); color: white; }
.install-help { margin: 16px 6px 0; color: var(--muted); font-size: .82rem; line-height: 1.45; text-align: center; }
.legal-link { margin: 18px 0 0; text-align: center; font-size: 13px; }
.legal-link a { color: #42627a; text-decoration: underline; text-underline-offset: 3px; }
.home-screen { min-height: 100dvh; padding: max(18px, env(safe-area-inset-top)) 20px calc(32px + env(safe-area-inset-bottom)); background: #f7fafc; }
.topbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; }
.mini-brand { display: flex; align-items: center; gap: 10px; }
.mini-brand img { width: 46px; height: 46px; border-radius: 14px; object-fit: cover; }
.mini-brand div { display: grid; }
.mini-brand strong { font-size: 1rem; }
.mini-brand span { color: var(--muted); font-size: .78rem; }
.logout-button { min-height: 40px; padding: 0 12px; border-radius: 12px; border: 1px solid var(--line); background: white; color: #a33c32; font-weight: 750; font-size: .76rem; }
.employee-card { display: flex; align-items: center; gap: 12px; padding: 14px; background: white; border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 8px 24px rgba(41,77,102,.05); }
.avatar { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 13px; background: #e5f7f1; color: #117b5e; font-weight: 900; }
.employee-card div:nth-child(2) { display: grid; flex: 1; }
.employee-card span { color: var(--muted); font-size: .76rem; }
.employee-card strong { font-size: .88rem; margin-top: 2px; }
.online-dot { width: 10px; height: 10px; border-radius: 50%; background: #20ad7f; box-shadow: 0 0 0 5px #e0f7ef; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 15px; margin: 28px 2px 14px; }
.section-heading h2 { margin: 5px 0 0; font-size: 1.45rem; letter-spacing: -.035em; }
.date-chip { padding: 7px 10px; border-radius: 11px; background: white; border: 1px solid var(--line); color: var(--muted); font-size: .78rem; white-space: nowrap; }
.jobs { display: grid; gap: 14px; }
.job-card { background: white; border: 1px solid var(--line); border-radius: 24px; padding: 20px; box-shadow: 0 15px 40px rgba(26,75,107,.09); }
.job-topline { display: flex; justify-content: space-between; gap: 10px; align-items: center; }
.order-badge { color: var(--blue-dark); background: var(--blue-soft); padding: 7px 10px; border-radius: 10px; font-weight: 850; font-size: .78rem; }
.status { padding: 7px 10px; border-radius: 999px; background: #f1f5f8; color: var(--muted); font-size: .75rem; font-weight: 800; }
.status.running { background: #fff1d8; color: #986000; }
.status.done { background: #e3f7ef; color: #0f795b; }
.job-card h3 { margin: 19px 0 5px; font-size: 1.5rem; letter-spacing: -.035em; }
.address { margin: 0; color: var(--muted); line-height: 1.45; }
.observation { margin: 13px 0 0; padding: 11px 13px; border-radius: 12px; background: #f5f8fa; color: #496074; font-size: .84rem; line-height: 1.45; }
.job-actions { display: grid; gap: 9px; margin-top: 16px; }
.job-warning,.urgent-notice,.blocked { display: grid; gap: 3px; margin-top: 13px; padding: 12px 13px; border-radius: 13px; background: #fff4df; color: #754f08; font-size: .8rem; line-height: 1.4; }
.urgent-notice { margin: 0 0 10px; }
.blocked { background: #fff0ed; color: #a13d2b; font-weight: 700; }
.loading-card,.empty-card { display: grid; gap: 5px; padding: 25px 18px; border: 1px solid var(--line); border-radius: 20px; background: white; color: var(--muted); text-align: center; }
.empty-card strong { color: var(--ink); }
.refresh-button { width: 100%; min-height: 46px; margin-top: 14px; border: 1px solid var(--line); border-radius: 14px; background: white; color: var(--blue-dark); font-weight: 800; }
.global-message { min-height: 20px; margin: 13px 3px 0; color: #a44432; text-align: center; font-size: .84rem; line-height: 1.45; }
.job-meta { display: flex; gap: 8px; flex-wrap: wrap; margin: 17px 0 20px; }
.job-meta span { padding: 7px 9px; border-radius: 9px; background: #f4f7f9; color: #52677a; font-size: .75rem; font-weight: 700; }
.gps-panel { display: flex; align-items: center; gap: 12px; padding: 14px; border-radius: 16px; background: #fff7e8; color: #714e0c; }
.gps-panel.ok { background: #e7f7f1; color: #12684f; }
.gps-icon { width: 38px; height: 38px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 12px; background: rgba(255,255,255,.75); font-size: 1.35rem; }
.gps-panel div:nth-child(2) { display: grid; gap: 2px; }
.gps-panel span { font-size: .76rem; line-height: 1.35; }
.secondary { margin-top: 14px; border: 1px solid #abd6ec; background: #f2faff; color: var(--blue-dark); }
.job-actions .secondary,.job-actions .clock-button { margin-top: 0; }
.clock-button { margin-top: 10px; }
.clock-button:disabled { background: #cbd8df; box-shadow: none; cursor: not-allowed; }
.bottom-nav { position: absolute; left: 12px; right: 12px; bottom: max(12px, env(safe-area-inset-bottom)); display: grid; grid-template-columns: repeat(4,1fr); padding: 9px 6px; background: rgba(255,255,255,.95); border: 1px solid var(--line); border-radius: 20px; box-shadow: 0 12px 35px rgba(16,36,58,.13); backdrop-filter: blur(16px); }
.bottom-nav button { display: grid; gap: 3px; place-items: center; border: 0; background: none; color: #7a8995; font-size: .67rem; font-weight: 700; }
.bottom-nav button span { font-size: 1.08rem; }
.bottom-nav button.active { color: var(--blue); }
.toast { position: fixed; z-index: 5; left: 50%; bottom: 28px; width: min(calc(100% - 40px),390px); padding: 13px 16px; transform: translate(-50%, 30px); opacity: 0; pointer-events: none; background: #10243a; color: white; border-radius: 14px; font-size: .85rem; text-align: center; transition: .25s ease; }
.toast.show { transform: translate(-50%,0); opacity: 1; }
.cahier-dialog { width: min(calc(100% - 28px), 410px); max-height: 82dvh; padding: 0; border: 0; border-radius: 22px; color: var(--ink); box-shadow: 0 24px 70px rgba(10,42,65,.28); }
.cahier-dialog::backdrop { background: rgba(10,32,49,.58); backdrop-filter: blur(3px); }
.dialog-head { position: sticky; top: 0; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 19px; border-bottom: 1px solid var(--line); background: white; }
.dialog-head h2 { margin: 4px 0 0; font-size: 1.3rem; }
.dialog-head button { width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 12px; background: white; color: var(--muted); font-size: 1.4rem; }
#cahierContent { display: grid; gap: 10px; padding: 18px; }
.task { display: grid; gap: 4px; padding: 14px; border-radius: 14px; background: #f5f8fa; }
.task span { color: var(--blue-dark); font-size: .76rem; font-weight: 800; }
.task p { margin: 4px 0 0; color: var(--muted); font-size: .84rem; line-height: 1.4; }
[hidden] { display: none !important; }
@media (min-width: 700px) { body { padding: 28px 0; } .app-shell { min-height: calc(100dvh - 56px); border-radius: 30px; } .login-screen,.home-screen { min-height: calc(100dvh - 56px); } }
