/* ═══════════════════════════════════════════════════
   FLEET INSPECTION SYSTEM — Styles
   ═══════════════════════════════════════════════════ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

:root {
  --bg:  #0f1209;
  --bg2: #161e0f;
  --bg3: #111509;
  --bdr: #2a3a1a;
  --bdr2: #1a2210;
  --tx:  #d8e4c0;
  --tx2: #e0ecc8;
  --tx3: #5a7040;
  --tx4: #3a4a28;
  --g:   #5cce8e;
  --y:   #f0b030;
  --r:   #e85858;
  --gr:  #7a8a6a;
  --pu:  #c098e8;
  --or:  #f0a060;
  --bl:  #7ac0e0;
}

html, body {
  height: 100%;
  background: var(--bg);
  color: var(--tx);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 15px;
  overflow-x: hidden;
}

#root {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 16px;
  min-height: 46px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 700;
  border: 2px solid;
  cursor: pointer;
  transition: opacity .15s;
  font-family: inherit;
  -webkit-user-select: none;
  user-select: none;
}
.btn:active { opacity: .7; }

.btn.g  { background: #1a2a14; border-color: #5cce8e60; color: var(--g); }
.btn.b  { background: #14242a; border-color: #4a9dbf60; color: var(--bl); }
.btn.r  { background: #2a1414; border-color: #e8585860; color: #ff8080; }
.btn.pu { background: #241a2a; border-color: #c098e860; color: var(--pu); }
.btn.or { background: #2a1e10; border-color: #f0a06060; color: var(--or); }
.btn.gr { background: #1a1e14; border-color: #5a6a4a60; color: var(--gr); }

.btn.lg { min-height: 54px; font-size: 15px; }
.btn.fw { width: 100%; }

/* ── Inputs ── */
.inp {
  width: 100%;
  background: #0a0d07;
  border: 2px solid var(--bdr);
  color: var(--tx2);
  font-size: 14px;
  padding: 12px 13px;
  border-radius: 6px;
  font-family: inherit;
  font-weight: 500;
  display: block;
  outline: none;
}
.inp:focus { border-color: var(--g); }
textarea.inp { resize: vertical; min-height: 90px; }

/* ── Status button ── */
.sb {
  width: 40px;
  height: 40px;
  border-radius: 6px;
  border: 2px solid;
  font-size: 19px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  -webkit-user-select: none;
  user-select: none;
  transition: transform .1s;
}
.sb:active { transform: scale(.88); }

/* ── Cards & Layout ── */
.card {
  background: var(--bg2);
  border: 2px solid var(--bdr);
  border-radius: 8px;
  padding: 14px;
}

.ov {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .88);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 500;
  padding: 16px;
}

.mo {
  background: var(--bg2);
  border: 2px solid #4a5a30;
  border-radius: 8px;
  padding: 22px;
  width: 100%;
  max-width: 440px;
  max-height: 92vh;
  overflow-y: auto;
}

/* ── Labels & Typography ── */
.lbl {
  font-size: 10px;
  color: #7a9050;
  letter-spacing: 2px;
  font-weight: 700;
  text-transform: uppercase;
}

.ts {
  font-size: 10px;
  color: #3a5a28;
  font-weight: 600;
  margin-top: 3px;
}

/* ── Progress bar ── */
.pbar { height: 6px; background: #1a2210; border-radius: 3px; overflow: hidden; }
.pfill { height: 100%; border-radius: 3px; transition: width .3s; }

/* ── Thumbnail ── */
.ptb {
  width: 64px;
  height: 64px;
  border-radius: 5px;
  border: 2px solid var(--bdr);
  object-fit: cover;
  cursor: pointer;
  display: block;
}

/* ── Badge ── */
.badge {
  background: #8B2020;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 10px;
}

/* ── Tabs ── */
.tabs {
  display: flex;
  background: var(--bg3);
  border-bottom: 2px solid var(--bdr2);
  overflow-x: auto;
}

.tab {
  flex: 1;
  min-width: 60px;
  padding: 13px 4px;
  font-size: 11px;
  font-weight: 700;
  border: none;
  border-bottom: 3px solid transparent;
  background: transparent;
  color: var(--tx4);
  cursor: pointer;
  font-family: inherit;
  white-space: nowrap;
}

.tab.on { color: var(--g); border-bottom-color: var(--g); background: rgba(92,206,142,.1); }
.tab.sn.on { color: #ff8080; border-bottom-color: var(--r); background: rgba(232,88,88,.08); }
.tab.pt.on { color: var(--pu); border-bottom-color: var(--pu); background: rgba(192,152,232,.08); }

/* ── Separator ── */
.sep { height: 2px; background: var(--bdr2); margin: 10px 0; }

/* ── Toast ── */
#toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  padding: 12px 22px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
  border: 2px solid;
  white-space: nowrap;
  display: none;
  z-index: 1000;
  max-width: 90vw;
  text-align: center;
  pointer-events: none;
}

/* ── PDF / Print CSS ── */
#print-css {
  display: none;
}
