/* Pathao Clips. One stylesheet for the rider site and the admin panel. */
:root {
  --ink: #1c1c1a;
  --muted: #5a5852;
  --line: #e2dfd8;
  --line2: #cfccc4;
  --ground: #f4f3ef;
  --card: #ffffff;
  --soft: #faf9f6;
  --red: #c01f25;
  --red-dark: #9a171c;
  --green: #1f6b3a;
  --amber: #8a5a00;
  --radius: 12px;
  --font: "Noto Sans Devanagari", "Mukta", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--ground); font-size: 16px; line-height: 1.45; }
a { color: var(--red); }
a:hover { color: var(--red-dark); }
h1, h2, h3 { margin: 0; line-height: 1.2; }
h1 { font-size: 26px; }
h2 { font-size: 20px; }
h3 { font-size: 17px; }
p { margin: 0; }
img { max-width: 100%; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.center { text-align: center; }
.stack { display: flex; flex-direction: column; gap: 16px; }
.stack-s { display: flex; flex-direction: column; gap: 8px; }
.row { display: flex; gap: 12px; align-items: center; }
.between { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.wrap { flex-wrap: wrap; }
.grow { flex-grow: 1; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.grid4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.mono { font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; }
.hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Cards */
.card { background: var(--card); border: 1.5px solid var(--ink); border-radius: var(--radius); padding: 16px; }
.soft { background: var(--card); border: 1px solid var(--line2); border-radius: var(--radius); padding: 14px; }
.dark { background: var(--ink); color: #fff; border-color: var(--ink); }
.dark .muted, .dark .label { color: #d6d3cb; }
.label { font-size: 12px; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.big-num { font-size: 32px; font-weight: 700; line-height: 1.1; }
.num { font-size: 22px; font-weight: 700; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 18px; border-radius: 10px; border: 0; background: var(--ink); color: #fff; font: inherit; font-weight: 600; font-size: 16px; text-decoration: none; cursor: pointer; }
.btn:hover { color: #fff; opacity: .92; }
.btn.red { background: var(--red); }
.btn.ghost { background: #fff; color: var(--ink); border: 1.5px solid var(--ink); }
.btn.ghost:hover { color: var(--ink); background: var(--soft); }
.btn.big { min-height: 56px; font-size: 17px; width: 100%; }
.btn.full { width: 100%; }
.btn.sm { min-height: 36px; font-size: 14px; padding: 0 12px; border-radius: 8px; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.linkbtn { background: none; border: 0; color: var(--red); font: inherit; cursor: pointer; padding: 0; text-decoration: underline; }
form.inline { display: inline; }

/* Forms */
label.field, .field { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 15px; }
.hint { font-weight: 400; font-size: 13px; color: var(--muted); }
.err { font-weight: 600; font-size: 13px; color: var(--red); }
input[type=text], input[type=tel], input[type=password], input[type=url], input[type=number], input[type=date], input[type=email], select, textarea {
  width: 100%; min-height: 52px; border: 1.5px solid #8f8c84; border-radius: 10px; background: #fff; padding: 10px 14px; font: inherit; font-size: 17px; color: var(--ink);
}
textarea { min-height: 90px; resize: vertical; }
input:focus, select:focus, textarea:focus, .btn:focus-visible, a:focus-visible, .tile:focus-within { outline: 3px solid #f0b429; outline-offset: 2px; }
input.invalid { border-color: var(--red); }
.pin-input { letter-spacing: 18px; font-size: 28px !important; text-align: center; font-weight: 700; max-width: 240px; }
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 64px; }
.pw-eye { position: absolute; right: 6px; top: 6px; bottom: 6px; border: 0; background: var(--ground); border-radius: 8px; padding: 0 10px; font: inherit; font-size: 13px; cursor: pointer; }
.check { display: flex; gap: 12px; align-items: center; font-size: 15px; font-weight: 600; }
.check input { width: 26px; height: 26px; accent-color: var(--ink); }

/* Service tiles (radio) */
.tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.tile { position: relative; }
.tile input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.tile span { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; height: 84px; border: 1.5px solid var(--ink); border-radius: var(--radius); background: #fff; font-weight: 700; font-size: 16px; }
.tile input:checked + span { background: var(--ink); color: #fff; }
.tile .dot { width: 20px; height: 20px; border-radius: 50%; border: 2px solid #8f8c84; }
.tile input:checked + span .dot { border-color: #fff; background: var(--red); }

/* Chips */
.chip { display: inline-block; font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 999px; border: 1px solid var(--ink); background: #fff; white-space: nowrap; }
.chip.ok { border-color: var(--green); color: var(--green); }
.chip.warn { border-color: var(--amber); color: var(--amber); }
.chip.bad { border-color: var(--red); color: var(--red); }
.chip.on { background: var(--ink); color: #fff; }
a.chip { text-decoration: none; color: var(--ink); }
a.chip.on { color: #fff; }

/* Flash */
.flash { padding: 12px 14px; border-radius: 10px; font-weight: 600; font-size: 15px; }
.flash.ok { background: #e7f3eb; color: var(--green); }
.flash.err { background: #fbe9e9; color: var(--red); }

/* Bars and charts */
.bar { height: 8px; border-radius: 4px; background: var(--line); overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--ink); }
.bar.hot > i { background: var(--red); }
.chart { display: flex; gap: 6px; align-items: flex-end; height: 140px; border-bottom: 1px solid var(--line2); padding: 0 4px; }
.chart .col { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 4px; height: 100%; min-width: 0; }
.chart .col i { display: block; width: 100%; background: var(--line2); border-radius: 4px 4px 0 0; min-height: 2px; }
.chart .col.hi i { background: var(--red); }
.chart .col small { font-size: 10px; color: var(--muted); white-space: nowrap; }
.stackbar { display: flex; height: 26px; border-radius: 6px; overflow: hidden; border: 1px solid var(--line2); }
.stackbar i { display: block; height: 100%; }
.legend { display: flex; gap: 18px; flex-wrap: wrap; font-size: 13px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend b.sw { width: 12px; height: 12px; border-radius: 3px; display: inline-block; border: 1px solid var(--line2); }

/* ---------------- Rider layout ---------------- */
.r-top { position: sticky; top: 0; z-index: 10; background: #fff; border-bottom: 1px solid var(--line); }
.r-top-in { max-width: 1120px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 16px; }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 18px; color: var(--ink); text-decoration: none; }
.brand i { width: 30px; height: 30px; border-radius: 8px; background: var(--red); display: inline-block; }
.brand:hover { color: var(--ink); }
.langs { display: inline-flex; border: 1px solid var(--ink); border-radius: 999px; overflow: hidden; font-size: 13px; }
.langs { margin: 0; }
.langs button { padding: 5px 11px; color: var(--ink); background: #fff; border: 0; font: inherit; font-size: 13px; cursor: pointer; }
.langs button.on { background: var(--ink); color: #fff; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--line2); display: inline-flex; align-items: center; justify-content: center; font-weight: 700; color: var(--ink); text-decoration: none; }
.r-main { max-width: 560px; margin: 0 auto; padding: 18px 16px 110px; display: flex; flex-direction: column; gap: 16px; }
.r-nav { position: fixed; bottom: 0; left: 0; right: 0; z-index: 10; background: #fff; border-top: 1px solid var(--line); display: flex; padding: 8px 4px calc(10px + env(safe-area-inset-bottom)); }
.r-nav a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 12px; color: var(--muted); text-decoration: none; padding: 4px 0; }
.r-nav a svg { width: 24px; height: 24px; }
.r-nav a.on { color: var(--red); font-weight: 700; }
.r-desk-nav { display: none; }
.helpbar { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.status-dot { width: 14px; height: 14px; border-radius: 50%; flex-shrink: 0; display: inline-block; }
.step { display: flex; gap: 14px; align-items: center; }
.step .n { width: 34px; height: 34px; border-radius: 50%; background: var(--red); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; flex-shrink: 0; }
.faq details { border-bottom: 1px solid var(--line); padding: 12px 0; }
.faq summary { font-weight: 700; cursor: pointer; }
.videobox { aspect-ratio: 16/9; background: var(--line); border-radius: var(--radius); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.videobox iframe { width: 100%; height: 100%; border: 0; }
.locked-wrap { position: relative; }
.locked-wrap .blur { filter: blur(5px); opacity: .5; pointer-events: none; user-select: none; }
.locked-card { position: absolute; left: 0; right: 0; top: 20px; box-shadow: 0 10px 30px rgba(28, 28, 26, .18); }
.lock-ico { width: 64px; height: 64px; border-radius: 50%; background: var(--ink); display: flex; align-items: center; justify-content: center; margin: 0 auto; }
.progress-steps { display: flex; flex-direction: column; gap: 12px; background: var(--ground); border-radius: 10px; padding: 14px; }
.pstep { display: flex; gap: 12px; align-items: center; }
.pstep b { width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--line2); flex-shrink: 0; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 14px; }
.pstep.done b { background: var(--green); border-color: var(--green); }
.pstep.now { font-weight: 700; }
.pstep.now b { border: 3px solid var(--amber); }
.camp-card { display: flex; flex-direction: column; gap: 10px; text-decoration: none; color: var(--ink); }
.camp-card:hover { color: var(--ink); background: var(--soft); }
.camp-card.full { opacity: .65; }
.pay-line { background: var(--ground); border-radius: 8px; padding: 10px; font-size: 15px; }
.list-row { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; border-bottom: 1px solid var(--line); gap: 10px; }
.list-row:last-child { border-bottom: 0; }
.lb-me { background: var(--ink); color: #fff; }

/* Auth pages: two columns on big screens */
.auth-main { max-width: 1180px; margin: 0 auto; padding: 18px 16px 40px; }
.auth-grid { display: flex; flex-direction: column; gap: 22px; }
.auth-side { display: none; }
.auth-card { display: flex; flex-direction: column; gap: 16px; }
.hero-title { font-size: 30px; font-weight: 800; line-height: 1.12; }
.site-foot { max-width: 1180px; margin: 0 auto; padding: 18px 16px 30px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 13px; color: var(--muted); }

@media (min-width: 900px) {
  .r-nav { display: none; }
  .r-desk-nav { display: flex; gap: 4px; }
  .r-desk-nav a { padding: 8px 12px; border-radius: 8px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15px; }
  .r-desk-nav a.on { background: var(--ground); color: var(--red); }
  .r-main { max-width: 720px; padding-bottom: 40px; }
  .auth-grid { display: grid; grid-template-columns: 1fr 560px; gap: 56px; align-items: start; padding-top: 24px; }
  .auth-side { display: flex; flex-direction: column; gap: 24px; }
  .auth-card { background: #fff; border: 1.5px solid var(--ink); border-radius: 14px; padding: 32px; box-shadow: 0 12px 40px rgba(28, 28, 26, .08); }
  .auth-card .only-mobile { display: none; }
  .hero-title { font-size: 50px; }
  .tiles.wide { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .auth-about { max-width: 720px; margin: 0 auto; }
}

/* ---------------- Admin ---------------- */
.a-body { background: var(--ground); font-size: 14px; }
.a-shell { display: flex; min-height: 100vh; }
.a-side { width: 236px; flex-shrink: 0; background: var(--ink); color: #e8e6e1; padding: 18px 12px; display: flex; flex-direction: column; gap: 2px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.a-side .brand { color: #fff; padding: 0 8px 16px; }
.a-side a.nav { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 9px 12px; border-radius: 8px; color: #e8e6e1; text-decoration: none; font-size: 14px; }
.a-side a.nav:hover { background: #2e2d2a; }
.a-side a.nav.on { background: #fff; color: var(--ink); font-weight: 700; }
.a-side .badge { background: var(--red); color: #fff; border-radius: 999px; font-size: 11px; padding: 1px 8px; font-weight: 700; }
.a-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.a-top { height: 60px; background: #fff; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; padding: 0 24px; gap: 12px; }
.a-top h1 { font-size: 20px; }
.a-content { padding: 22px 24px 40px; display: flex; flex-direction: column; gap: 18px; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; }
.kpi { background: #fff; border: 1px solid var(--line2); border-radius: 10px; padding: 14px; }
.kpi .v { font-size: 22px; font-weight: 700; margin-top: 4px; }
.tbl-wrap { background: #fff; border: 1px solid var(--line2); border-radius: 10px; overflow-x: auto; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 13px; }
.tbl th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); background: var(--soft); padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl td.r, .tbl th.r { text-align: right; }
.cols-2 { display: grid; grid-template-columns: 1fr 420px; gap: 18px; align-items: start; }
.cols-3 { display: grid; grid-template-columns: 300px 1fr 330px; gap: 16px; align-items: start; }
.cols-eq { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; align-items: start; }
.a-body input[type=text], .a-body input[type=password], .a-body input[type=email], .a-body input[type=number], .a-body input[type=date], .a-body input[type=url], .a-body select, .a-body textarea { min-height: 40px; font-size: 14px; padding: 8px 10px; border-radius: 8px; }
.a-body label.field { font-size: 13px; }
.a-body .btn { min-height: 40px; font-size: 14px; }
.a-body .btn.sm { min-height: 32px; font-size: 13px; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.qlist a { display: block; padding: 12px; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.qlist a.on, .qlist a:hover { background: var(--ground); }
.signal { display: grid; grid-template-columns: 1.3fr 1fr 1fr 60px; gap: 10px; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.proof-img { max-height: 420px; border-radius: 8px; border: 1px solid var(--line2); }
.login-box { max-width: 400px; margin: 10vh auto; }
@media (max-width: 1100px) {
  .cols-2, .cols-3 { grid-template-columns: 1fr; }
}
@media (max-width: 800px) {
  .a-shell { flex-direction: column; }
  .a-side { width: 100%; height: auto; position: static; flex-direction: row; flex-wrap: wrap; }
  .a-side .brand { width: 100%; }
}
