/* Shared base styles (login, capture, admin). Bangla-capable fonts. */
@import url('https://fonts.googleapis.com/css2?family=Hind+Siliguri:wght@400;500;600;700&display=swap');

:root {
  --bg: #f4f6fa; --card: #fff; --text: #172033; --muted: #6b7690; --line: #e1e6ef;
  --primary: #1d4ed8; --primary-d: #1639a5; --ok: #15803d; --warn: #b45309; --err: #b91c1c;
  --radius: 14px; --shadow: 0 1px 3px rgba(20,30,60,.08), 0 6px 20px rgba(20,30,60,.06);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { font-size: 16px; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: 'Hind Siliguri', 'Noto Sans Bengali', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.45;
}
img { max-width: 100%; }
a { color: var(--primary); text-decoration: none; }
h1, h2, h3 { margin: 0 0 .5rem; line-height: 1.2; }
.muted { color: var(--muted); }
.hidden { display: none !important; }

label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: .85rem; }
input, select, textarea {
  display: block; width: 100%; margin-top: .3rem; padding: .75rem .85rem; font: inherit; color: inherit;
  background: #fff; border: 1.5px solid var(--line); border-radius: 10px; min-height: 46px;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(29,78,216,.15); }
input[type=checkbox], input[type=radio] { display: inline-block; width: auto; min-height: 0; margin: 0 .4rem 0 0; }
input[type=color] { padding: 2px; min-height: 46px; }
textarea { min-height: 80px; resize: vertical; }
.field-error { color: var(--err); font-size: .8rem; font-weight: 500; margin-top: .25rem; }
input.invalid, select.invalid { border-color: var(--err); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  padding: .7rem 1.1rem; min-height: 46px; font: inherit; font-weight: 600; cursor: pointer;
  border: 1.5px solid var(--line); border-radius: 12px; background: #fff; color: var(--text);
}
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-d); }
.btn-danger { background: #fff; border-color: #f2b8b8; color: var(--err); }
.btn-ok { background: var(--ok); border-color: var(--ok); color: #fff; }
.btn-sm { min-height: 36px; padding: .35rem .7rem; font-size: .85rem; border-radius: 9px; }
.btn-lg { min-height: 56px; font-size: 1.1rem; border-radius: 14px; }
.btn-block { display: flex; width: 100%; }
.btn[disabled] { opacity: .5; pointer-events: none; }

.alert { padding: .7rem .9rem; border-radius: 10px; margin-bottom: 1rem; font-size: .92rem; }
.alert-error { background: #fdecec; color: var(--err); border: 1px solid #f6c5c5; }
.alert-ok { background: #e8f6ed; color: var(--ok); border: 1px solid #bfe3cc; }
.alert-warn { background: #fff6e5; color: var(--warn); border: 1px solid #f3d9a3; }

.badge { display: inline-block; padding: .1rem .55rem; border-radius: 99px; font-size: .75rem; font-weight: 600; background: #eef1f7; color: var(--muted); }
.badge.done { background: #e1f4e8; color: var(--ok); }
.badge.pending, .badge.processing { background: #e6eefc; color: var(--primary); }
.badge.failed { background: #fdecec; color: var(--err); }
.badge.manual_check { background: #fff1d6; color: var(--warn); }

.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); transform: translateX(-50%) translateY(20px);
  background: #111827; color: #fff; padding: .65rem 1.1rem; border-radius: 99px; font-weight: 600; font-size: .92rem;
  opacity: 0; transition: .25s; z-index: 9999; pointer-events: none; max-width: 90vw; text-align: center;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.err { background: var(--err); }

/* login */
.login-body { display: grid; place-items: center; min-height: 100vh; padding: 16px; }
.login-card { width: 100%; max-width: 380px; background: var(--card); border-radius: 20px; padding: 28px 24px; box-shadow: var(--shadow); text-align: center; }
.login-card form { text-align: left; margin-top: 1rem; }
.logo { font-size: 3rem; }
