/* Staff app: quiet and dense. The customer quote page carries the visual identity. */
.shell { display: grid; grid-template-columns: 220px 1fr; min-height: 100vh; }
.side { background: var(--ink); color: #fff; padding: 18px 14px; display: flex; flex-direction: column; gap: 4px; position: sticky; top: 0; height: 100vh; }
.side .brand { margin: 0 6px 6px; color: #fff; }
.side .app-name { margin: 0 6px 20px; font-family: var(--display); font-size: 20px; color: #e8d3a6; }
.side a { color: #cfd6e6; text-decoration: none; padding: 8px 10px; border-radius: var(--r-s); font-weight: 500; }
.side a:hover { background: rgba(255,255,255,.07); color: #fff; }
.side a[aria-current] { background: rgba(255,255,255,.12); color: #fff; }
.side .who { margin-top: auto; font-size: 13px; color: #9fa9c2; padding: 0 10px; }
.side .who button { background: none; border: 0; color: #cfd6e6; padding: 0; text-decoration: underline; cursor: pointer; }
.main { padding: 26px clamp(16px, 3vw, 36px) 60px; min-width: 0; }
.head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.head h1 { font-size: 30px; }
.panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-m); padding: 18px; margin-bottom: 16px; }
.panel > h2 { font-size: 19px; margin-bottom: 12px; }
.btn { border: 1px solid var(--ink); background: var(--ink); color: #fff; padding: 8px 14px; border-radius: var(--r-s); cursor: pointer; font-weight: 600; font-size: 14px; text-decoration: none; display: inline-block; text-align: center; }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.small { padding: 4px 10px; font-size: 13px; }
.btn.danger { border-color: var(--red); color: var(--red); background: transparent; }
.btn:disabled { opacity: .5; cursor: default; }
label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
input, select, textarea { border: 1px solid var(--line); border-radius: var(--r-s); padding: 7px 9px; background: #fff; font-size: 14px; font-weight: 400; min-width: 0; }
input:focus, select:focus, textarea:focus { border-color: var(--ink); outline: none; box-shadow: 0 0 0 3px rgba(19,34,74,.12); }
textarea { min-height: 70px; resize: vertical; }
.grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.grid.wide { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.row { display: flex; gap: 8px; align-items: end; flex-wrap: wrap; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-size: 12px; color: var(--ink-2); font-weight: 600; padding: 6px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 6px 8px; border-bottom: 1px solid #eef0f4; vertical-align: middle; }
td input, td select { width: 100%; padding: 5px 7px; }
tr.click { cursor: pointer; } tr.click:hover td { background: #f8f9fb; }
.scroll { overflow-x: auto; }
.pill { display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 99px; background: #eef0f4; }
.pill.sent { background: #e6eefb; } .pill.accepted { background: #e3f3ea; color: var(--ok); } .pill.lost { background: #fde8e8; color: var(--red); }
.city-makkah { color: var(--makkah); } .city-madinah { color: var(--madinah); }
.muted { color: var(--ink-2); font-size: 13px; }
.warn { background: #fff4e5; border: 1px solid #f3d19c; color: #7a4b00; padding: 8px 12px; border-radius: var(--r-s); font-size: 13px; margin-bottom: 10px; }
.empty { text-align: center; padding: 40px 10px; color: var(--ink-2); }

/* Quote builder: form on the left, live price on the right */
.builder { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 16px; align-items: start; }
.live { position: sticky; top: 16px; background: var(--paper); border: 1px solid var(--line); border-top: 3px solid var(--gold); border-radius: var(--r-m); padding: 18px; }
.live h2 { font-size: 19px; }
.live .pp { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; margin: 12px 0; }
.live .pp b { font-family: var(--display); font-size: 22px; color: var(--gold); font-weight: 600; text-align: right; }
.live .tot { border-top: 1px solid var(--line); padding-top: 10px; display: grid; grid-template-columns: 1fr auto; gap: 3px 10px; font-size: 14px; }
.live .tot .big { font-family: var(--display); font-size: 26px; }
.live .actions { display: grid; gap: 8px; margin-top: 14px; }
.stay { border: 1px solid var(--line); border-radius: var(--r-m); padding: 12px; margin-bottom: 10px; border-left: 4px solid var(--makkah); }
.stay.madinah { border-left-color: var(--madinah); }
.pick { display: grid; grid-template-columns: auto 1fr auto; gap: 8px 10px; align-items: center; padding: 6px 0; border-bottom: 1px solid #eef0f4; font-size: 14px; }
.pick input[type=number] { width: 64px; }
.check { flex-direction: row; align-items: center; gap: 6px; font-weight: 500; color: var(--ink); }

.login { min-height: 100vh; display: grid; place-items: center; padding: 20px; }
.login form { width: min(380px, 100%); background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-m); padding: 28px; display: grid; gap: 14px; }
.login h1 { font-size: 28px; }
#toast { position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 10px 16px; border-radius: var(--r-s); font-size: 14px; opacity: 0; pointer-events: none; transition: opacity .2s; }
#toast.on { opacity: 1; }
#toast.err { background: var(--red); }

@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: static; height: auto; flex-direction: row; flex-wrap: wrap; align-items: center; }
  .side .app-name { display: none; } .side .who { margin: 0 0 0 auto; }
  .builder { grid-template-columns: 1fr; } .live { position: static; }
}
