/* Shared external-portal primitives used by the supplier surface. */
body { margin: 0; }
.sub-app, .sub-login-body { min-height: 100vh; background: #f8fafc; color: #0f172a; }
.sub-header { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px max(18px, env(safe-area-inset-right)) 14px max(18px, env(safe-area-inset-left)); background: #fff; border-bottom: 1px solid #e2e8f0; }
.sub-header-brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.sub-header-brand img { width: 42px; height: 42px; object-fit: contain; border-radius: 8px; }
.sub-header-name { font-size: 16px; font-weight: 700; color: #7f1d1d; }
.sub-header-trade { font-size: 12px; color: #64748b; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sub-header-logout { border: 1px solid #cbd5e1; border-radius: 8px; background: #fff; color: #475569; padding: 8px 12px; font-weight: 600; cursor: pointer; }
.sub-content { display: none; width: min(100% - 28px, 920px); margin: 0 auto; padding: 22px 0 52px; }
.sub-content.active { display: block; }
.sub-welcome h2 { margin: 0 0 4px; font-size: 24px; color: #7f1d1d; }
.sub-welcome p, .sub-card-subtitle { margin: 0; color: #64748b; font-size: 14px; line-height: 1.45; }
.sub-section-title { margin: 24px 0 10px; color: #475569; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.sub-card { margin-bottom: 10px; padding: 16px; background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; box-shadow: 0 2px 8px rgba(15,23,42,.04); }
.sub-card-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.sub-card-title { color: #0f172a; font-weight: 700; }
.sub-card-meta { margin-top: 5px; color: #94a3b8; font-size: 12px; }
.sub-card-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.sub-btn, .sub-btn-sm { border: 0; border-radius: 9px; background: #7f1d1d; color: #fff; padding: 11px 16px; font: 600 14px inherit; cursor: pointer; }
.sub-btn-sm { padding: 7px 11px; font-size: 12px; }
.sub-btn:disabled { opacity: .45; cursor: not-allowed; }
.sub-btn-accept { background: #166534; }
.sub-badge { display: inline-flex; border-radius: 999px; padding: 4px 9px; font-size: 11px; font-weight: 700; }
.sub-badge-pending { background: #fef3c7; color: #92400e; }
.sub-badge-submitted { background: #dbeafe; color: #1e40af; }
.sub-badge-ordered { background: #dcfce7; color: #166534; }
.sub-empty { padding: 22px; text-align: center; color: #94a3b8; border: 1px dashed #cbd5e1; border-radius: 10px; }
.sub-file-upload { margin-top: 10px; padding: 22px; text-align: center; border: 2px dashed #cbd5e1; border-radius: 10px; background: #f8fafc; cursor: pointer; }
.sub-file-upload-name { margin-top: 6px; color: #7f1d1d; font-weight: 600; }
.sub-success { margin-top: 8px; color: #166534; font-size: 13px; }
.sub-error { min-height: 18px; margin-top: 8px; color: #b91c1c; font-size: 13px; }
.sub-modal-overlay { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 18px; background: rgba(15,23,42,.65); }
.sub-modal { width: min(100%, 700px); overflow: auto; padding: 20px; background: #fff; border-radius: 16px; box-shadow: 0 24px 70px rgba(0,0,0,.3); }
.sub-modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.sub-modal-title { font-size: 18px; font-weight: 700; }
.sub-modal-close { border: 0; background: transparent; font-size: 28px; color: #64748b; cursor: pointer; }
.sub-login-body { display: grid; place-items: center; padding: 24px; background: linear-gradient(145deg,#7f1d1d,#111827 65%); }
.sub-login-card { width: min(100%, 390px); padding: 30px; background: #fff; border-radius: 18px; box-shadow: 0 24px 70px rgba(0,0,0,.32); }
.sub-login-brand { text-align: center; }
.sub-login-brand img { width: 80px; height: 80px; object-fit: contain; }
.sub-login-brand h1 { margin: 10px 0 3px; color: #7f1d1d; }
.sub-login-brand p, .sub-footer-text { color: #64748b; font-size: 13px; }
.sub-phone-input { box-sizing: border-box; width: 100%; margin-top: 22px; padding: 12px 14px; border: 1px solid #cbd5e1; border-radius: 9px; font: 15px inherit; }
.sub-login-card .sub-btn { width: 100%; }
.sub-footer-text { margin-top: 22px; text-align: center; line-height: 1.5; }
@media (max-width: 560px) { .sub-card { padding: 14px; } .sub-header { padding-top: max(12px, env(safe-area-inset-top)); } }
