:root {
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  color: #172033;
  background: #f3f5f7;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; }
.auth-page { display: grid; place-items: center; padding: 24px; background: linear-gradient(135deg, #f7f8fa, #e8edf2); }
.auth-card { width: min(100%, 440px); background: #fff; border-radius: 18px; padding: 34px; box-shadow: 0 20px 60px rgba(28,45,70,.13); }
.logo { width: 150px; max-height: 70px; object-fit: contain; object-position: left center; }
.eyebrow { margin: 20px 0 6px; font-size: 12px; font-weight: 800; letter-spacing: .14em; color: #68768a; }
h1 { margin: 0 0 8px; font-size: clamp(28px, 6vw, 38px); letter-spacing: -.03em; }
.subtitle, .hint { color: #68768a; line-height: 1.55; }
form { margin-top: 26px; }
label { display: block; margin: 16px 0 7px; font-size: 14px; font-weight: 700; }
input { width: 100%; border: 1px solid #ccd3dc; border-radius: 10px; padding: 13px 14px; font-size: 16px; outline: none; }
input:focus { border-color: #5a6b80; box-shadow: 0 0 0 3px rgba(90,107,128,.12); }
button { width: 100%; margin-top: 20px; border: 0; border-radius: 10px; padding: 13px 18px; font-weight: 800; cursor: pointer; background: #1d2b3d; color: white; }
button:disabled { opacity: .6; cursor: wait; }
.message { min-height: 22px; margin-top: 12px; color: #b42318; font-size: 14px; }
.hint { margin: 20px 0 0; font-size: 13px; }
.topbar { display: flex; justify-content: space-between; gap: 20px; align-items: center; padding: 14px 28px; background: white; border-bottom: 1px solid #e3e7ec; }
.brand, .userbox { display: flex; align-items: center; gap: 14px; font-weight: 750; }
.brand img { width: 100px; max-height: 44px; object-fit: contain; }
.secondary { width: auto; margin: 0; background: #eef1f4; color: #172033; padding: 9px 14px; }
.dashboard-shell { max-width: 980px; margin: 72px auto; padding: 0 24px; }
.info-card { margin-top: 28px; display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 1px; background: #dfe4ea; border: 1px solid #dfe4ea; border-radius: 14px; overflow: hidden; }
.info-card div { background: white; padding: 20px; display: grid; gap: 6px; }
.info-card span { color: #68768a; font-size: 13px; }
.next-phase { margin-top: 26px; font-weight: 700; }
@media (max-width: 640px) {
  .auth-card { padding: 26px 22px; }
  .topbar { align-items: flex-start; padding: 14px 16px; }
  .brand span { display: none; }
  .userbox { gap: 8px; }
  .info-card { grid-template-columns: 1fr; }
  .dashboard-shell { margin-top: 42px; }
}
.role-badge { display:inline-flex; align-items:center; border:1px solid #d8dee6; border-radius:999px; padding:5px 9px; font-size:11px; letter-spacing:.08em; background:#f7f8fa; }
.role-panels { margin-top:24px; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; }
.role-card { background:white; border:1px solid #e0e5eb; border-radius:14px; padding:22px; }
.role-card h2 { margin:6px 0 8px; font-size:20px; }
.role-card p { margin:0; color:#68768a; line-height:1.55; }
.card-kicker { font-size:11px; font-weight:800; letter-spacing:.12em; color:#68768a; }
.admin-card { border-width:2px; }
.admin-check { margin-top:16px; padding:11px 12px; border-radius:9px; background:#f3f5f7; font-size:13px; font-weight:700; }
[hidden] { display:none !important; }
@media (max-width: 640px) { .role-panels { grid-template-columns:1fr; } .role-badge { display:none; } }

.primary-link{display:inline-block;padding:10px 14px;border-radius:9px;background:#14365d;color:#fff;text-decoration:none;font-weight:800}
.nav-link{display:inline-block;text-decoration:none;font-size:13px;font-weight:800}.history-shell{max-width:1200px;margin-top:46px}.history-title{display:flex;justify-content:space-between;gap:24px;align-items:end}.history-tools{margin:26px 0 14px;display:flex;gap:12px;align-items:end}.history-tools input{max-width:520px}.history-tools label{margin:0;min-width:180px}.history-tools select{width:100%;margin-top:7px;border:1px solid #ccd3dc;border-radius:10px;padding:12px;background:white}.history-message{padding:10px 0;color:#68768a;font-weight:700}.history-table-wrap{overflow:auto;background:white;border:1px solid #e0e5eb;border-radius:14px}.history-table{width:100%;border-collapse:collapse;min-width:900px}.history-table th,.history-table td{padding:14px 16px;text-align:left;border-bottom:1px solid #edf0f3;font-size:14px}.history-table th{font-size:12px;letter-spacing:.04em;color:#68768a;background:#fafbfc}.history-table tr:last-child td{border-bottom:0}.quote-number{font-weight:850;color:#14365d;text-decoration:none}.money-cell{font-weight:800;white-space:nowrap}.status-pill{display:inline-block;padding:5px 8px;border-radius:999px;background:#f0f3f6;font-size:12px;font-weight:750}.row-actions{display:flex;gap:8px;align-items:center;white-space:nowrap}.mini-link{font-weight:750;color:#14365d;text-decoration:none}.copy-btn{width:auto;margin:0;padding:7px 10px;background:#eef1f4;color:#172033;font-size:12px}@media(max-width:720px){.history-title{align-items:flex-start;flex-direction:column}.history-tools{align-items:stretch;flex-direction:column}.history-tools input{max-width:none}}
.audit-table{min-width:1050px}.audit-table td code{white-space:pre-wrap;word-break:break-word;font-size:11px;color:#465469}.security-card{margin-top:16px}.security-actions{display:flex;gap:10px;align-items:center;flex-wrap:wrap}.security-actions button{margin:0;width:auto}.security-note{font-size:13px;color:#68768a}
