:root {
  --bg: #f3f7fb;
  --card: #fff;
  --ink: #102033;
  --muted: #6b7b8d;
  --line: #dce6ef;
  --blue: #0c74d4;
  --blue2: #07579f;
  --ok: #168a4c;
  --warn: #c67a00;
  --bad: #c53939;
  --shadow: 0 12px 35px rgba(18, 49, 82, 0.08);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    Segoe UI,
    sans-serif;
  background: var(--bg);
  color: var(--ink);
}
button,
input,
select,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
}
.hidden {
  display: none !important;
}
.muted {
  color: var(--muted);
}
.login-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at top right, #d8efff, transparent 38%),
    linear-gradient(135deg, #eff8ff, #f8fbfd);
}
.login-card {
  width: min(92vw, 410px);
  background: #fff;
  padding: 34px;
  border-radius: 24px;
  box-shadow: var(--shadow);
  text-align: center;
}
.brand-mark {
  width: 58px;
  height: 58px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--blue), #23a3f7);
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 900;
  font-size: 24px;
  margin: 0 auto 12px;
}
.brand-mark.small {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  font-size: 18px;
  margin: 0;
}
.login-card h1 {
  margin: 0;
}
.login-card form {
  display: grid;
  gap: 14px;
  text-align: left;
  margin: 28px 0 16px;
}
.app {
  display: grid;
  grid-template-columns: 250px 1fr;
  min-height: 100vh;
}
.sidebar {
  background: #0d2740;
  color: #fff;
  padding: 20px 14px;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 8px 24px;
}
.brand small {
  display: block;
  opacity: 0.65;
  margin-top: 2px;
}
.sidebar nav {
  display: grid;
  gap: 6px;
}
.sidebar nav button,
.sidebar .ghost {
  border: 0;
  background: transparent;
  color: #bdd0e1;
  text-align: left;
  padding: 12px 14px;
  border-radius: 12px;
}
.sidebar nav button:hover,
.sidebar nav button.active {
  background: #163a5d;
  color: #fff;
}
.sidebar-footer {
  margin-top: auto;
  border-top: 1px solid #214563;
  padding-top: 16px;
}
.sidebar-footer #meBox {
  padding: 0 10px 10px;
  font-size: 13px;
}
.sidebar-footer .ghost {
  width: 100%;
}
main {
  min-width: 0;
  padding: 0 28px 36px;
}
header {
  height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  margin-bottom: 24px;
}
header h2 {
  margin: 0;
  font-size: 24px;
}
header p {
  margin: 4px 0 0;
}
.cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 18px;
  box-shadow: 0 2px 8px rgba(15, 39, 63, 0.03);
}
.metric b {
  font-size: 30px;
  display: block;
  margin-top: 6px;
}
.section {
  margin-top: 20px;
}
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.section-head h3 {
  margin: 0;
}
.primary,
.secondary,
.danger,
.ghost {
  border: 0;
  border-radius: 11px;
  padding: 10px 14px;
  font-weight: 700;
}
.primary {
  background: var(--blue);
  color: #fff;
}
.primary:hover {
  background: var(--blue2);
}
.secondary {
  background: #e9f3fd;
  color: #07579f;
}
.danger {
  background: #feecec;
  color: var(--bad);
}
.ghost {
  background: #eef3f7;
  color: #35506a;
}
.full {
  width: 100%;
}
label {
  display: grid;
  gap: 6px;
  font-size: 13px;
  font-weight: 650;
  color: #3d536a;
}
input,
select,
textarea {
  width: 100%;
  border: 1px solid #cfdce7;
  border-radius: 10px;
  padding: 10px 11px;
  background: #fff;
  color: var(--ink);
}
textarea {
  min-height: 86px;
  resize: vertical;
}
.grid {
  display: grid;
  gap: 14px;
}
.g2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.g3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.g4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.wizard {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}
.wizard span {
  padding: 8px 12px;
  border-radius: 999px;
  background: #e9eff5;
  color: #617589;
  font-size: 13px;
}
.wizard span.active {
  background: var(--blue);
  color: #fff;
}
.table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}
table {
  border-collapse: collapse;
  width: 100%;
  min-width: 720px;
}
th,
td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  font-size: 13px;
}
th {
  background: #f6f9fb;
  color: #5b7187;
}
.badge {
  display: inline-flex;
  align-items: center;
  padding: 5px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  background: #eaf1f6;
  color: #456;
}
.badge.ok {
  background: #e7f8ef;
  color: var(--ok);
}
.badge.warn {
  background: #fff4df;
  color: var(--warn);
}
.badge.bad {
  background: #feecec;
  color: var(--bad);
}
.actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.actions button {
  padding: 7px 9px;
  font-size: 12px;
}
.item-card {
  display: grid;
  grid-template-columns: 90px 1fr auto;
  gap: 14px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px;
  margin-top: 10px;
}
.item-card img {
  width: 90px;
  height: 74px;
  object-fit: cover;
  border-radius: 10px;
  background: #eef3f7;
}
.env-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  margin-top: 12px;
  overflow: hidden;
}
.env-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 13px 15px;
  background: #f7fafc;
}
.env-body {
  padding: 12px 15px;
}
.checkrow {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
}
.checkrow input {
  width: auto;
}
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(5, 20, 35, 0.54);
  display: grid;
  place-items: center;
  padding: 20px;
  z-index: 20;
}
.modal {
  background: #fff;
  width: min(920px, 100%);
  max-height: 92vh;
  overflow: auto;
  border-radius: 20px;
  padding: 20px;
  box-shadow: var(--shadow);
}
.modal h3 {
  margin-top: 0;
}
.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 16px;
}
.toast {
  position: fixed;
  right: 20px;
  top: 20px;
  z-index: 99;
  background: #102c46;
  color: #fff;
  padding: 12px 15px;
  border-radius: 12px;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(-10px);
  pointer-events: none;
  transition: 0.2s;
}
.toast.show {
  opacity: 1;
  transform: none;
}
.toast.success {
  background: #176b43;
}
.toast.error {
  background: #9d3030;
}
.photo-preview {
  width: 150px;
  height: 110px;
  object-fit: cover;
  border-radius: 12px;
  background: #edf2f6;
  border: 1px solid var(--line);
}
.os-detail .env-card.done {
  border-color: #9fd6b8;
}
.os-detail .env-card.done .env-head {
  background: #effaf4;
}
.permission-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 14px;
  background: #f6f9fb;
  border-radius: 12px;
  padding: 12px;
}
.empty {
  padding: 28px;
  text-align: center;
  color: var(--muted);
}
@media (max-width: 980px) {
  .app {
    grid-template-columns: 78px 1fr;
  }
  .sidebar {
    padding: 16px 8px;
  }
  .brand > div,
  .sidebar nav span,
  .sidebar-footer #meBox {
    display: none;
  }
  .brand {
    justify-content: center;
  }
  .sidebar nav button {
    text-align: center;
    font-size: 18px;
  }
  .cards {
    grid-template-columns: repeat(2, 1fr);
  }
  main {
    padding: 0 16px 28px;
  }
  .g4 {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 620px) {
  .app {
    grid-template-columns: 1fr;
  }
  .sidebar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    top: auto;
    height: 66px;
    z-index: 15;
    display: block;
    padding: 7px;
    background: #0d2740;
  }
  .brand,
  .sidebar-footer {
    display: none;
  }
  .sidebar nav {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
  }
  .sidebar nav button {
    padding: 9px 3px;
    font-size: 16px;
  }
  .sidebar nav button span {
    display: block;
    font-size: 10px;
    margin-top: 2px;
  }
  .sidebar nav button[style*="display: none"] {
    display: none !important;
  }
  main {
    padding: 0 12px 82px;
  }
  header {
    height: 72px;
  }
  .cards,
  .g2,
  .g3,
  .g4 {
    grid-template-columns: 1fr;
  }
  .item-card {
    grid-template-columns: 70px 1fr;
  }
  .item-card img {
    width: 70px;
    height: 62px;
  }
  .item-card .actions {
    grid-column: 1/-1;
  }
  .modal {
    padding: 15px;
    border-radius: 16px;
  }
}
/* TJ CLEAN: blue glass, clear typography, generous working space. */
:root {
  --bg: #f3f6fa;
  --ink: #142740;
  --muted: #64758b;
  --line: #e0e7f0;
  --blue: #0867e9;
  --blue2: #0054c5;
  --shadow: 0 20px 70px #061c3920;
}
body {
  font-size: 16px;
  line-height: 1.5;
}
button {
  font-size: 14px;
  min-height: 42px;
  transition:
    background 0.15s,
    transform 0.15s;
}
button:disabled {
  opacity: 0.55;
  cursor: wait;
}
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid #4ea5ff;
  outline-offset: 3px;
}
h1,
h2,
h3 {
  letter-spacing: -0.035em;
}
h3 {
  font-size: 19px;
}
input,
select,
textarea {
  font-size: 16px;
  min-height: 46px;
}
label,
th,
td,
.actions button,
.wizard span {
  font-size: 14px;
}
small {
  font-size: 13px;
}
.badge {
  font-size: 12px;
  white-space: nowrap;
  padding: 5px 10px;
}
.primary {
  box-shadow: 0 3px 8px #0867e923;
  font-weight: 600;
  border-radius: 9px;
}
.secondary,
.ghost,
.danger {
  border-radius: 8px;
  font-weight: 600;
}
.app {
  grid-template-columns: 240px 1fr;
}
.sidebar {
  background: #0b203b;
  padding: 30px 16px;
}
.brand {
  padding-bottom: 44px;
}
.brand b {
  font-size: 19px;
  letter-spacing: 0.015em;
}
.brand small {
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.brand-mark {
  background: #0b72f5;
  border-radius: 12px;
}
.sidebar nav button {
  margin-bottom: 4px;
  font-size: 16px;
  padding: 14px 12px;
  border-radius: 9px;
}
.sidebar nav button.active {
  background: #0a68e6;
  box-shadow: 0 5px 14px #0002;
}
.sidebar nav button:hover:not(.active) {
  background: #163958;
}
.sidebar-footer #meBox {
  font-size: 14px;
  overflow-wrap: anywhere;
}
.sidebar-footer span {
  font-size: 12px;
  color: #a9bed4;
}
.sidebar-footer .ghost {
  font-size: 14px;
}
main {
  padding: 0 36px 40px;
}
header {
  height: 98px;
  margin-bottom: 28px;
}
header h2 {
  font-size: 21px;
}
header p {
  font-size: 14px;
}
header > .ghost {
  font-size: 13px;
  background: white;
  border: 1px solid var(--line);
}
.eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #6f8299;
}
.dashboard-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin: 8px 0 28px;
}
.dashboard-heading h1 {
  font-size: clamp(26px, 3vw, 38px);
  margin: 6px 0;
  font-weight: 650;
}
.dashboard-heading p {
  margin: 0;
  font-size: 14px;
}
.card {
  border-radius: 13px;
  padding: 22px;
  box-shadow: 0 4px 16px #162d4910;
}
.cards {
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(175px, 1fr));
}
.metric {
  padding: 22px 24px;
}
.metric > span {
  font-size: 14px;
  color: #54677d;
}
.metric b {
  font-size: 38px;
  font-weight: 600;
  letter-spacing: -0.04em;
  margin: 8px 0;
}
.metric small {
  color: var(--muted);
  font-size: 12px;
}
.metric-blue {
  background: #0969e9;
  color: white;
  border-color: #0969e9;
}
.metric-blue > span,
.metric-blue small {
  color: #deecff;
}
.dashboard-columns {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 22px;
  margin-top: 26px;
}
.upcoming .section-head {
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.upcoming h3 {
  margin: 4px 0 0;
}
.upcoming .ghost {
  background: transparent;
  color: var(--blue);
  white-space: nowrap;
}
.empty-state {
  text-align: center;
  padding: 40px 12px 32px;
}
.empty-symbol {
  display: grid;
  place-items: center;
  margin: auto;
  width: 54px;
  height: 54px;
  background: #ebf3ff;
  color: var(--blue);
  border: 1px solid #d5e5ff;
  border-radius: 15px;
  font-size: 26px;
}
.empty-state h3 {
  font-size: 18px;
  margin: 18px 0 6px;
  letter-spacing: -0.02em;
}
.empty-state p {
  color: var(--muted);
  font-size: 14px;
  margin: 0 0 20px;
}
.side-stack {
  display: grid;
  gap: 20px;
  align-content: start;
}
.finance-card {
  background: #e9f2ff;
  border-color: #d7e6fb;
}
.finance-card p {
  font-size: 14px;
  margin: 14px 0 3px;
}
.finance-card strong {
  font-size: 29px;
  font-weight: 650;
  letter-spacing: -0.04em;
  color: #0756b5;
}
.finance-card small {
  display: block;
  margin-top: 12px;
  font-size: 12px;
  color: #577390;
}
.quick-card h3 {
  margin: 0 0 12px;
}
.quick-card > button {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  border: 0;
  border-top: 1px solid var(--line);
  padding: 13px 0;
  background: white;
  text-align: left;
  font-size: 14px;
  color: #314c6b;
}
.service-row {
  display: flex;
  gap: 14px;
  align-items: center;
  width: 100%;
  background: none;
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 18px 0;
  text-align: left;
}
.service-row:last-child {
  border: 0;
}
.service-info {
  display: grid;
  flex: 1;
  gap: 3px;
  min-width: 0;
}
.service-info b {
  font-size: 15px;
}
.service-info span,
.service-info small {
  font-size: 13px;
  color: var(--muted);
  overflow-wrap: anywhere;
}
.date-tile {
  background: #f0f5fb;
  border: 1px solid var(--line);
  border-radius: 10px;
  width: 54px;
  flex: none;
  text-align: center;
  padding: 7px;
}
.date-tile b {
  display: block;
  font-size: 22px;
  line-height: 1.1;
}
.date-tile span {
  font-size: 12px;
}
.table-wrap {
  box-shadow: 0 4px 16px #162d4908;
}
th {
  padding: 15px 16px;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
td {
  padding: 16px;
  vertical-align: middle;
}
td.actions {
  display: table-cell;
}
td.actions button {
  margin: 2px;
}
.wizard {
  margin-bottom: 26px;
}
.wizard span {
  background: white;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 10px 18px;
}
.wizard span.active {
  background: #e5f0ff;
  border-color: #bfd8fc;
  color: #0757b6;
  font-weight: 700;
}
.env-card,
.item-card {
  background: white;
}
.photo-preview {
  width: 80px;
  height: 74px;
}
.modal-backdrop {
  backdrop-filter: blur(3px);
}
.modal {
  padding: 28px;
  border-radius: 16px;
}
.modal h3 {
  font-size: 22px;
  margin-bottom: 22px;
}
.modal-footer {
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.toast {
  max-width: calc(100vw - 32px);
  font-size: 14px;
}
.login-shell {
  grid-template-columns: 1.05fr 1fr;
  background: #f5f8fd;
  padding: 0;
  min-height: 100dvh;
}
.login-intro {
  height: 100%;
  min-height: 100dvh;
  width: 100%;
  padding: 60px 12%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: #092c58;
  color: white;
  border-right: 8px solid #147afb;
}
.login-intro .eyebrow {
  color: #96bdeb;
  letter-spacing: 0.15em;
}
.login-intro h2 {
  font-size: clamp(36px, 4.5vw, 68px);
  line-height: 1.1;
  font-weight: 600;
  letter-spacing: -0.05em;
  margin: 55px 0 25px;
}
.login-intro em {
  font-style: normal;
  color: #6fb6ff;
}
.login-intro > p {
  color: #bed1e9;
  max-width: 340px;
  line-height: 1.7;
}
.login-bottom {
  margin-top: 70px;
  font-size: 12px;
  letter-spacing: 0.12em;
  color: #96bdeb;
}
.login-card {
  width: min(410px, 85%);
  box-shadow: none;
  background: transparent;
  padding: 36px 12px;
  text-align: left;
}
.login-card .brand-mark {
  margin: 0 0 22px;
  width: 54px;
  height: 54px;
}
.login-card h1 {
  font-size: 30px;
  letter-spacing: 0.01em;
}
.login-card form {
  margin: 32px 0 22px;
  gap: 20px;
}
.login-card .primary {
  min-height: 48px;
  font-size: 16px;
}
.login-hint {
  font-size: 13px;
  line-height: 1.6;
}
.login-card > p {
  font-size: 14px;
}
#mobileExit {
  display: none;
}
@media (min-width: 1500px) {
  main {
    padding-left: 50px;
    padding-right: 50px;
  }
  .dashboard-columns {
    grid-template-columns: minmax(0, 1fr) 320px;
  }
}
@media (max-width: 1100px) {
  .app {
    grid-template-columns: 210px 1fr;
  }
  main {
    padding-left: 24px;
    padding-right: 24px;
  }
  .dashboard-columns {
    grid-template-columns: 1fr;
  }
  .side-stack {
    grid-template-columns: 1fr 1fr;
  }
  .cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .brand > div,
  .sidebar nav span,
  .sidebar-footer #meBox {
    display: block;
  }
  .brand {
    justify-content: flex-start;
  }
  .sidebar nav button {
    text-align: left;
  }
  .dashboard-heading {
    align-items: flex-start;
  }
  .dashboard-heading > .primary {
    max-width: 200px;
  }
}
@media (max-width: 760px) {
  .app {
    grid-template-columns: 1fr;
  }
  .sidebar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    top: auto;
    height: auto;
    min-height: 74px;
    z-index: 15;
    padding: 8px 6px max(8px, env(safe-area-inset-bottom));
    display: block;
  }
  .sidebar .brand,
  .sidebar-footer {
    display: none;
  }
  .sidebar nav {
    display: flex;
    gap: 5px;
  }
  .sidebar nav button {
    flex: 1;
    text-align: center;
    padding: 7px 4px;
    margin: 0;
    font-size: 18px;
    line-height: 1.2;
  }
  .sidebar nav button span {
    display: block;
    font-size: 12px;
    margin-top: 5px;
    line-height: 1.2;
  }
  main {
    padding: 0 18px 115px;
  }
  header {
    height: auto;
    min-height: 86px;
    gap: 10px;
    margin-bottom: 22px;
  }
  header h2 {
    font-size: 19px;
  }
  header p {
    display: none;
  }
  header > .ghost {
    font-size: 12px;
    padding: 7px;
  }
  .dashboard-heading {
    display: block;
    margin-bottom: 22px;
  }
  .dashboard-heading > .primary {
    margin-top: 20px;
    max-width: none;
  }
  .dashboard-heading h1 {
    font-size: 29px;
  }
  .cards {
    gap: 12px;
  }
  .metric {
    padding: 17px;
  }
  .metric b {
    font-size: 31px;
  }
  .metric small {
    display: none;
  }
  .metric > span {
    font-size: 13px;
  }
  .dashboard-columns {
    gap: 14px;
    margin-top: 18px;
  }
  .side-stack {
    grid-template-columns: 1fr;
  }
  .card {
    padding: 18px;
  }
  .upcoming .section-head {
    gap: 5px;
  }
  .upcoming h3 {
    font-size: 17px;
  }
  .upcoming .ghost {
    font-size: 12px;
    padding: 6px;
  }
  .service-row {
    flex-wrap: wrap;
    gap: 10px;
  }
  .service-row > .badge {
    margin-left: 64px;
  }
  .service-row > span:last-child {
    display: none;
  }
  .service-info {
    min-width: calc(100% - 80px);
  }
  .g2,
  .g3,
  .g4 {
    grid-template-columns: 1fr;
  }
  .permission-grid {
    grid-template-columns: 1fr;
  }
  .modal-backdrop {
    padding: 12px;
  }
  .modal {
    max-height: 92dvh;
    padding: 20px;
    border-radius: 14px;
  }
  .modal-footer {
    flex-wrap: wrap;
  }
  .modal-footer button {
    flex: 1;
  }
  .env-head,
  .section-head {
    flex-wrap: wrap;
  }
  .item-card {
    grid-template-columns: 65px minmax(0, 1fr);
  }
  .item-card img,
  .item-card .photo-preview {
    width: 60px;
    height: 60px;
  }
  .item-card .actions {
    grid-column: 1/-1;
  }
  .wizard {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
  }
  .wizard span {
    font-size: 13px;
    padding: 8px 12px;
  }
  .login-shell {
    grid-template-columns: 1fr;
    align-content: center;
    gap: 0;
  }
  .login-intro {
    display: none;
  }
  .login-card {
    width: min(410px, 90%);
    padding: 36px 16px;
  }
  .login-card .brand-mark {
    width: 62px;
    height: 62px;
  }
  .login-card h1 {
    font-size: 32px;
  }
  #mobileExit {
    display: block;
    font-size: 13px;
    background: white;
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--muted);
    padding: 7px;
  }
  .toast {
    right: 16px;
    top: 16px;
  }
  header > div:first-child {
    flex: 1;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}
.login-logo {
  display: block;
  width: min(250px, 78vw);
  height: auto;
  margin: 0 0 20px;
  object-fit: contain;
}
.sidebar .brand {
  display: flex;
  justify-content: center;
  padding: 0 4px 32px;
}
.sidebar-logo {
  display: block;
  width: 150px;
  height: 150px;
  object-fit: contain;
  background: #fff;
  border-radius: 18px;
  padding: 7px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.2);
}
@media (max-width: 1100px) and (min-width: 761px) {
  .sidebar-logo {
    width: 125px;
    height: 125px;
  }
  .sidebar .brand {
    padding-bottom: 26px;
  }
}
@media (max-width: 760px) {
  .sidebar .brand {
    display: none;
  }
  .login-logo {
    width: min(235px, 74vw);
    margin: 0 auto 24px;
  }
  .login-card {
    text-align: center;
  }
  .login-card form {
    text-align: left;
  }
  .login-card .ghost.full {
    margin-top: 4px;
  }
}
.fin-toolbar {
  display: flex;
  gap: 14px;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.fin-tabs {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}
.fin-tabs button {
  border: 1px solid var(--line);
  background: white;
  color: var(--muted);
  padding: 10px 14px;
  border-radius: 8px;
}
.fin-tabs button.selected {
  background: #0867e9;
  color: white;
  border-color: #0867e9;
}
.fin-filters {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: end;
  margin-bottom: 20px;
}
.fin-filters label {
  flex: 1;
  min-width: 150px;
}
.fin-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
  margin: 16px 0 20px;
}
.fin-metrics span {
  font-size: 14px;
  color: var(--muted);
}
.fin-metrics strong {
  display: block;
  font-size: 26px;
  margin-top: 10px;
  letter-spacing: -0.04em;
}
.fin-alert {
  border-left: 4px solid #d46937;
}
.fin-note {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.65;
  margin: 14px 0 24px;
}
.fin-trip-grid,
.fin-report-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.fin-trip-grid dl {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  font-size: 14px;
}
.fin-trip-grid dd {
  margin: 0;
  font-weight: 700;
}
.negative {
  color: #b83c35;
}
.positive {
  color: #147d54;
}
.fin-cost-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  padding: 12px 0;
}
.fin-cost-row meter {
  width: 100%;
  height: 9px;
  grid-column: 1/-1;
  accent-color: #0867e9;
}
.fin-payment {
  display: flex;
  gap: 15px;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  flex-wrap: wrap;
}
.fin-payment small {
  color: var(--muted);
}
.fin-connection {
  background: #eaf3ff;
  border-left: 4px solid #0867e9;
}
.fin-connection h3 {
  margin: 0 0 10px;
}
.fin-message {
  white-space: pre-wrap;
  line-height: 1.7;
  padding: 16px;
  background: #f3f7fb;
  border-radius: 9px;
  font-size: 15px;
}
.fin-link {
  text-decoration: none;
  display: inline-block;
  text-align: center;
}
@media (max-width: 760px) {
  .fin-tabs {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
  }
  .fin-tabs button {
    padding: 9px 5px;
    font-size: 13px;
  }
  .fin-toolbar > .primary {
    width: 100%;
  }
  .fin-filters {
    padding: 14px;
  }
  .fin-filters label {
    min-width: calc(50% - 12px);
  }
  .fin-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .fin-metrics .card {
    padding: 14px;
  }
  .fin-metrics strong {
    font-size: 21px;
    overflow-wrap: anywhere;
  }
  .fin-trip-grid,
  .fin-report-grid {
    grid-template-columns: 1fr;
  }
  .sidebar nav button span {
    font-size: 11px;
  }
  .sidebar nav button {
    min-width: 0;
  }
  .fin-payment {
    font-size: 14px;
  }
}
@media print {
  .sidebar,
  header,
  .fin-toolbar,
  .fin-filters,
  .modal-backdrop,
  .toast,
  button {
    display: none !important;
  }
  .app {
    display: block;
  }
  main {
    padding: 0 !important;
  }
  .card {
    box-shadow: none;
    break-inside: avoid;
  }
  .fin-report-grid {
    display: block;
  }
  body {
    background: white;
    color: black;
  }
  .fin-metrics {
    grid-template-columns: repeat(2, 1fr);
  }
  .table-wrap {
    overflow: visible;
  }
  .fin-note {
    font-size: 12px;
  }
}
.stock-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}
.stock-extra {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  grid-column: 1/-1;
}
.stock-extra p {
  grid-column: 1/-1;
}
@media (max-width: 760px) {
  .stock-extra {
    grid-template-columns: 1fr;
  }
  #nav {
    overflow-x: auto;
    justify-content: flex-start;
  }
  #nav button {
    flex: 0 0 92px;
    min-width: 92px;
  }
  #nav button span {
    font-size: 12px;
  }
}
#passkeyLogin {
  margin-top: 14px;
}
#loginForm .checkrow {
  font-size: 14px;
  line-height: 1.4;
}
#myAccess {
  white-space: nowrap;
}
#enrollF {
  margin-top: 18px;
}
.photo-choices {
  grid-column: 1/-1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 14px;
  background: #f3f7fb;
  border: 1px solid var(--line);
  border-radius: 12px;
}
@media (max-width: 760px) {
  .photo-choices {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 760px) {
  main > header {
    flex-wrap: wrap;
    gap: 8px;
  }
  main > header > div {
    flex: 1 1 100%;
  }
  #myAccess {
    font-size: 14px;
  }
}

/* Logo oficial fornecida em PDF: proporção original preservada. */
.login-logo {
  width: min(300px, 78vw);
}
.sidebar-logo {
  height: auto;
}
@media (max-width: 1100px) and (min-width: 761px) {
  .sidebar-logo {
    height: auto;
  }
}
