/* Superior Cleaning - mobile first, no framework */
:root {
  --blue: #2d4f8a; --blue-d: #213c6b; --bg: #f4f6f9; --card: #fff; --line: #dde2ea; --text: #1f2633;
  --muted: #7a8494; --red: #c62828; --green: #2e7d32; --hover: #eef3fb;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font: 15px/1.45 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; color: var(--text); background: var(--bg); }
a { color: var(--blue); }
h1 { font-size: 22px; margin: 4px 0 16px; }
h2 { font-size: 17px; margin: 0 0 12px; }

/* top bar */
.topbar { position: sticky; top: 0; z-index: 10; background: var(--blue); color: #fff; display: flex; align-items: center; flex-wrap: wrap; padding: 0 12px; min-height: 54px; box-shadow: 0 1px 4px rgba(0,0,0,.15); }
.brand { color: #fff; text-decoration: none; font-weight: 600; display: flex; align-items: center; gap: 8px; padding: 10px 0; }
.brand img { width: 30px; height: 30px; border-radius: 6px; background: #fff; }
.burger { margin-left: auto; cursor: pointer; padding: 10px 4px; display: flex; flex-direction: column; gap: 5px; }
.burger span { display: block; width: 24px; height: 3px; background: #fff; border-radius: 2px; }
.nav { display: none; width: 100%; flex-direction: column; padding-bottom: 8px; }
#navtoggle:checked ~ .nav { display: flex; }
.nav a { color: #e6ecf7; text-decoration: none; padding: 11px 6px; border-top: 1px solid rgba(255,255,255,.12); }
.nav a.on { color: #fff; font-weight: 600; }
.adminbar { background: #fff4d6; color: #7a5a00; text-align: center; font-size: 13px; padding: 5px; border-bottom: 1px solid #f0dc9a; }
@media (min-width: 800px) {
  .burger { display: none; }
  .nav { display: flex; flex-direction: row; width: auto; flex: 1; padding: 0; margin-left: 28px; }
  .nav a { border: 0; padding: 17px 12px; }
  .nav a.on { box-shadow: inset 0 -3px 0 #fff; }
  .nav .me { margin-left: auto; }
}

.main { max-width: 1200px; margin: 0 auto; padding: 16px 14px 70px; }
.foot { position: fixed; bottom: 0; left: 0; right: 0; background: #e9edf3; border-top: 1px solid var(--line); text-align: center; font-size: 12px; color: #555; padding: 5px; }

/* filters */
.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; }
select, input[type=text], input[type=password] { font: inherit; padding: 9px 10px; border: 1px solid #c5ccd8; border-radius: 6px; background: #fff; width: 100%; max-width: 360px; }
.filters select { flex: 1 1 220px; }

/* lists */
table { border-collapse: collapse; width: 100%; }
table.list { background: var(--card); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.list th, .list td { padding: 10px 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.list th { background: #edf1f7; font-size: 13px; white-space: nowrap; }
.list th a { color: var(--text); text-decoration: none; display: block; }
.list tr.link { cursor: pointer; }
.list tr.link:hover td { background: var(--hover); }
.list td a { color: inherit; text-decoration: none; }
.list tr.overdue td, .list tr.overdue td a { color: var(--red); }
.num { text-align: right !important; }
.nowrap { white-space: nowrap; }
.muted { color: var(--muted); }
.red { color: var(--red); }
.tag { display: inline-block; font-size: 11px; background: #e3f1e4; color: var(--green); border-radius: 10px; padding: 0 7px; margin-left: 4px; }
.late { color: #b45309; font-weight: 600; }
.tag.late-tag { background: #fdecc8; color: #8a4b00; font-weight: 600; }
.empty { color: var(--muted); font-style: italic; }

/* detail pages */
.cols { display: grid; grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 900px) { .cols { grid-template-columns: 1fr 1fr; } }
table.info { background: var(--card); border: 1px solid var(--line); border-radius: 8px; margin-bottom: 16px; }
.info th, .info td { padding: 9px 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.info th { width: 38%; color: #4a5568; font-weight: 600; }
.info th.head { width: auto; background: #edf1f7; }
.checklist td { font-size: 16px; }
.checklist td.tick { width: 52px; text-align: center; }
.checklist input { width: 24px; height: 24px; }
.checklist label { display: block; cursor: pointer; }
.map { width: 100%; height: 380px; border-radius: 8px; border: 1px solid var(--line); background: #e5e9f0; }
.nomap { display: flex; align-items: center; justify-content: center; color: var(--muted); height: 120px; }

/* buttons */
.buttons { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 4px 0 20px; }
.buttons form { margin: 0; }
.btn { display: inline-block; font: inherit; font-weight: 600; padding: 11px 20px; min-width: 120px; text-align: center; border-radius: 6px; border: 1px solid #c5ccd8; background: #fff; color: var(--text); text-decoration: none; cursor: pointer; }
.btn.primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn.primary:hover { background: var(--blue-d); }
.btn.wide { width: 100%; }

/* forms / alerts */
label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 12px; }
label input[type=text], label input[type=password] { display: block; margin-top: 5px; max-width: none; }
label.check { font-weight: normal; display: flex; align-items: center; gap: 8px; }
label.check input { width: 18px; height: 18px; }
.stack { max-width: 380px; }
.alert { padding: 10px 12px; border-radius: 6px; margin-bottom: 14px; font-weight: 600; }
.alert.err { background: #fdecea; color: var(--red); }
.alert.ok { background: #e8f5e9; color: var(--green); }

/* login */
.loginbox { max-width: 380px; margin: 8vh auto 0; background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 24px; box-shadow: 0 4px 18px rgba(0,0,0,.06); }
.logintitle { display: flex; align-items: center; gap: 12px; font-weight: 700; font-size: 17px; margin-bottom: 18px; line-height: 1.2; }
.logintitle img { width: 44px; height: 44px; border-radius: 8px; }
.logintitle small { font-weight: 400; color: var(--muted); }

@media (max-width: 560px) { .hide-s { display: none; } h1 { font-size: 19px; } }

/* no focus ring on mouse clicks (keyboard focus keeps it) */
a:focus:not(:focus-visible), button:focus:not(:focus-visible), label:focus:not(:focus-visible) { outline: none; }

/* login code */
.codeinput { font-size: 26px !important; letter-spacing: 8px; text-align: center; font-weight: 700; }
.small { font-size: 12.5px; margin: -6px 0 14px; }
.resend { margin-top: 14px; text-align: center; font-size: 14px; }
.linkbtn { background: none; border: 0; padding: 0; font: inherit; color: var(--blue); text-decoration: underline; cursor: pointer; }
