/* SE-PMS mobile field portal */
.sepms-field { max-width: 720px; margin: 0 auto; padding: 12px 12px 90px; font-family: -apple-system, "Segoe UI", Tahoma, sans-serif; }
.sepms-topbar { display: flex; align-items: center; justify-content: space-between; padding: 8px 0 14px; }
.sepms-brand { font-size: 20px; font-weight: 700; letter-spacing: .2px; }
.sepms-sub { font-size: 12px; color: #6b7280; }
.sepms-h { margin: 18px 0 8px; font-size: 14px; color: #374151; }

.sepms-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 12px; }
.kpi { background: #f3f6fa; border-radius: 10px; padding: 10px 6px; text-align: center; }
.kpi b { display: block; font-size: 19px; }
.kpi span { font-size: 10px; color: #6b7280; }
.kpi.warn { background: #fff5e6; } .kpi.bad { background: #fdeaea; }

.sepms-search input { width: 100%; padding: 10px 12px; border: 1px solid #d5dae1; border-radius: 10px; margin-bottom: 12px; }

.sepms-list { display: flex; flex-direction: column; gap: 10px; }
.sepms-card { background: #fff; border: 1px solid #e5e9ef; border-radius: 12px; padding: 12px; box-shadow: 0 1px 2px rgba(16,24,40,.04); }
.sepms-card.link { display: block; color: inherit; text-decoration: none; }
.sepms-card .row { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.wo-no { font-weight: 700; font-size: 15px; }
.wo-scope { font-size: 13px; color: #374151; margin-top: 2px; }
.wo-loc { font-size: 12px; color: #6b7280; margin-top: 2px; }
.meta { display: flex; justify-content: space-between; font-size: 11px; color: #6b7280; margin-top: 6px; }
.bar { height: 5px; background: #eef1f5; border-radius: 4px; margin-top: 6px; overflow: hidden; }
.bar span { display: block; height: 100%; background: #2490ef; }
.actions { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }

.kv { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 5px 0; font-size: 13px; border-bottom: 1px dashed #eef1f5; }
.kv span { color: #6b7280; }

.pill { font-size: 11px; padding: 2px 8px; border-radius: 999px; background: #eef1f5; color: #374151; white-space: nowrap; }
.pill.green { background: #e6f6ec; color: #14622f; }
.pill.red { background: #fdeaea; color: #a11; }
.pill.orange { background: #fff3e0; color: #8a4b00; }
.pill.tiny { font-size: 9px; }

.sepms-btn { border: 1px solid #d5dae1; background: #fff; border-radius: 9px; padding: 8px 12px; font-size: 13px; cursor: pointer; text-decoration: none; color: #111827; display: inline-block; }
.sepms-btn.primary { background: #2490ef; color: #fff; border-color: #2490ef; }
.sepms-btn.ghost { background: #f7f9fb; }
.sepms-btn.full { width: 100%; text-align: left; margin-bottom: 6px; }
.sepms-btn.tiny { padding: 3px 8px; font-size: 11px; }

.sepms-section { font-weight: 700; font-size: 13px; padding: 8px 4px 2px; color: #1f2937; }
.item.critical { border-left: 3px solid #e53e3e; }
.q-en { font-size: 13px; font-weight: 600; }
.q-ar { font-size: 13px; color: #374151; direction: rtl; text-align: right; margin-top: 2px; }
.choices { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 8px; }
.choice { padding: 9px 4px; border: 1px solid #d5dae1; background: #fff; border-radius: 8px; font-size: 12px; cursor: pointer; }
.choice.on.Yes { background: #e6f6ec; border-color: #38a169; color: #14622f; font-weight: 600; }
.choice.on.No { background: #fdeaea; border-color: #e53e3e; color: #a11; font-weight: 600; }
.choice.on.NA { background: #eef1f5; border-color: #9aa4b2; font-weight: 600; }
.remark { width: 100%; margin-top: 8px; padding: 8px; border: 1px solid #e5b4b4; border-radius: 8px; font-size: 12px; }

.lbl { display: block; font-size: 11px; color: #6b7280; margin: 8px 0 3px; }
.sepms-card textarea, .sepms-card input[type="text"], .sepms-card input:not([type]) { width: 100%; border: 1px solid #d5dae1; border-radius: 8px; padding: 8px; font-size: 13px; }
.photo-list { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.photo-list img { width: 68px; height: 68px; object-fit: cover; border-radius: 8px; border: 1px solid #e5e9ef; }

.sepms-sticky { position: fixed; left: 0; right: 0; bottom: 0; background: #fff; border-top: 1px solid #e5e9ef; padding: 10px 12px; display: flex; gap: 8px; align-items: center; justify-content: flex-end; max-width: 720px; margin: 0 auto; }
.score { margin-right: auto; font-size: 12px; font-weight: 600; padding: 6px 10px; border-radius: 8px; background: #eef1f5; }
.score.good { background: #e6f6ec; color: #14622f; }
.score.warn { background: #fff3e0; color: #8a4b00; }
.score.bad { background: #fdeaea; color: #a11; }

.sepms-empty { text-align: center; color: #9aa4b2; padding: 24px; font-size: 13px; }
.sepms-modal { display: none; position: fixed; inset: 0; background: rgba(17,24,39,.45); z-index: 1050; align-items: flex-end; }
.sepms-modal.open { display: flex; }
.sepms-modal-card { background: #fff; width: 100%; max-width: 720px; margin: 0 auto; border-radius: 16px 16px 0 0; padding: 16px; max-height: 80vh; overflow: auto; }

@media (max-width: 420px) { .sepms-kpis { grid-template-columns: repeat(2, 1fr); } }
