/* City Solicitors CRM — design system ported from Figma Make "CITY SOLICITORS" */
:root{
  --navy:#122747;--navy-deep:#0b1830;--navy-secondary:#1b365d;
  --gold:#d6b15e;--gold-light:#f1d797;--gold-text:#9b782d;
  --bg:#f4f6f9;--text:#172033;--text-2:#667085;--border:#e4e7ec;
  --success:#16835a;--success-bg:#ecf8f3;--warning:#a15c07;--warning-bg:#fff7e6;
  --danger:#c4323f;--danger-bg:#fff0f1;--info:#245ea8;--info-bg:#edf5ff;
  --shadow-sm:0 1px 2px rgba(16,24,40,.05);--shadow-md:0 12px 32px rgba(11,24,48,.09);
  --radius:8px;
}
*{box-sizing:border-box}
html,body{margin:0}
body{font-family:"Inter",system-ui,-apple-system,"Segoe UI",sans-serif;color:var(--text);background:var(--bg);font-size:13px;line-height:1.5;-webkit-font-smoothing:antialiased}
a{color:var(--navy-secondary);text-decoration:none}
a:hover{color:var(--navy)}
button,input,select,textarea{font:inherit}
button{cursor:pointer}
h1,h2,h3,h4{color:var(--navy-deep);letter-spacing:-.02em}
.icon{flex:0 0 auto}

/* ---------- App shell ---------- */
.app{display:grid;grid-template-columns:240px minmax(0,1fr);min-height:100vh}
.sidebar{position:sticky;top:0;height:100vh;background:var(--navy-deep);color:#fff;display:flex;flex-direction:column;overflow:hidden}
.brand{height:150px;display:flex;align-items:center;justify-content:center;border-bottom:1px solid rgba(255,255,255,.07);overflow:hidden}
.brand img{width:150px;height:150px;object-fit:contain}
.nav-label{padding:18px 20px 10px;color:#718097;font-size:10px;font-weight:700;letter-spacing:.16em}
.sidebar nav{flex:1;min-height:0;padding:0 12px;display:flex;flex-direction:column;gap:2px;overflow-y:auto}
.sidebar .nav-link{position:relative;height:42px;padding:0 12px;border-radius:6px;color:#9eabba;display:flex;align-items:center;gap:12px;font-size:13px;transition:.17s ease}
.sidebar .nav-link span{flex:1}
.sidebar .nav-link:hover,.sidebar .nav-link.active{color:#fff;background:rgba(255,255,255,.06)}
.sidebar .nav-link.active::before{content:"";position:absolute;left:-12px;top:8px;bottom:8px;width:3px;background:var(--gold)}
.sidebar .nav-link.active .icon{color:var(--gold)}
.sidebar .nav-link i{min-width:20px;height:20px;padding:0 6px;border-radius:10px;color:var(--navy-deep);background:var(--gold);display:grid;place-items:center;font-size:10px;font-style:normal;font-weight:700}
.sidebar .logout{margin:8px 12px 0;padding-top:4px;border-top:1px solid rgba(255,255,255,.07);border-radius:0}
.side-user{height:68px;padding:12px 16px;border-top:1px solid rgba(255,255,255,.07);display:flex;align-items:center;gap:10px;color:#fff}
.side-user .av{width:36px;height:36px;border-radius:50%;color:var(--navy);background:var(--gold-light);display:grid;place-items:center;font-size:12px;font-weight:700;flex:0 0 auto}
.side-user span{min-width:0;flex:1}
.side-user strong,.side-user small{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.side-user strong{font-size:12.5px}
.side-user small{color:#7f8ca0;font-size:11px;margin-top:2px}
.main{min-width:0;display:flex;flex-direction:column}
.topbar{position:sticky;top:0;z-index:10;height:66px;padding:0 28px;background:#fff;border-bottom:1px solid var(--border);display:flex;align-items:center;justify-content:space-between;gap:16px}
.global-search{width:380px;height:40px;padding:0 12px;border:1px solid var(--border);border-radius:6px;color:#8d97a7;display:flex;align-items:center;gap:8px}
.global-search input{flex:1;min-width:0;border:0;outline:0;background:transparent;color:var(--text);font-size:13px;padding:0;box-shadow:none}
.global-search kbd{color:#98a2b3;font-size:11px;font-family:inherit}
.top-right{display:flex;align-items:center;gap:14px}
.bell{position:relative;padding:6px;color:#667085;display:flex}
.bell .dot{position:absolute;top:0;right:0;min-width:16px;height:16px;padding:0 4px;border-radius:8px;background:var(--gold);color:var(--navy-deep);border:2px solid #fff;font-size:9px;font-weight:700;display:grid;place-items:center}
.user-chip{display:flex;align-items:center;gap:10px}
.user-chip .avatar{width:36px;height:36px;border-radius:50%;background:#e8edf4;color:var(--navy);display:grid;place-items:center;font-weight:700;font-size:12px}
.user-chip strong,.user-chip small{display:block}
.user-chip strong{font-size:12.5px;color:var(--navy-deep)}
.user-chip small{font-size:11px;color:var(--text-2)}
.content{flex:1;padding:28px;min-width:0}

/* ---------- Page title ---------- */
.page-head{margin-bottom:22px;display:flex;align-items:flex-start;justify-content:space-between;gap:16px}
.page-head .eyebrow{color:var(--gold-text);font-size:10px;font-weight:700;letter-spacing:.15em;text-transform:uppercase}
.page-head h1{margin:6px 0 4px;font-size:26px;line-height:1.2;letter-spacing:-.025em;font-weight:600}
.page-head p{margin:0;color:var(--text-2);font-size:12.5px}
.page-actions{display:flex;gap:10px;align-items:center}

/* ---------- Buttons ---------- */
.btn{min-height:40px;padding:0 16px;border:1px solid transparent;border-radius:6px;background:var(--gold);color:var(--navy-deep);font-size:12.5px;font-weight:600;display:inline-flex;align-items:center;justify-content:center;gap:8px;white-space:nowrap;transition:.15s}
.btn:hover{background:var(--gold-light);color:var(--navy-deep)}
.btn-primary,.btn-gold{background:var(--gold);color:var(--navy-deep)}
.btn-primary:hover,.btn-gold:hover{background:var(--gold-light);color:var(--navy-deep)}
.btn-navy{background:var(--navy);color:#fff}
.btn-navy:hover{background:var(--navy-secondary);color:#fff}
.btn-outline{background:#fff;color:var(--navy);border-color:#ccd3dc}
.btn-outline:hover{background:#f8fafc;border-color:var(--navy);color:var(--navy)}
.btn-danger{background:#fff;color:var(--danger);border-color:#f2c6cb}
.btn-danger:hover{background:var(--danger-bg);color:var(--danger)}
.btn-sm{min-height:32px;padding:0 12px;font-size:12px}
.btn-block{width:100%}

/* ---------- Cards / panels ---------- */
.card,.panel{min-width:0;border:1px solid var(--border);border-radius:var(--radius);background:#fff;box-shadow:var(--shadow-sm)}
.panel{margin-bottom:18px}
.panel-header{min-height:56px;padding:12px 20px;border-bottom:1px solid var(--border);display:flex;align-items:center;justify-content:space-between;gap:12px}
.panel-header h3{margin:0;font-size:14px;font-weight:600;color:var(--navy-deep)}
.panel-header .meta{color:var(--text-2);font-size:12px}
.panel-body{padding:18px 20px}
.cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:14px;margin-bottom:18px}
.stat-card{position:relative;padding:18px 18px 16px;display:flex;flex-direction:column}
.stat-card .stat-accent{position:absolute;top:16px;right:16px;width:34px;height:34px;border-radius:6px;display:grid;place-items:center;background:#edf2f8;color:var(--navy);font-weight:700;font-size:12px}
.stat-card:nth-child(4n+2) .stat-accent{background:#fff6df;color:#80601d}
.stat-card:nth-child(4n+3) .stat-accent{background:var(--warning-bg);color:var(--warning)}
.stat-card:nth-child(4n+4) .stat-accent{background:var(--success-bg);color:var(--success)}
.stat-card .stat-label{order:1;color:var(--text-2);font-size:12px;font-weight:500;padding-right:44px}
.stat-card .stat-value{order:2;margin-top:12px;font-size:28px;font-weight:700;color:var(--navy-deep);letter-spacing:-.02em;line-height:1.1}
.stat-card .stat-detail{order:3;margin-top:6px;font-size:11px;color:var(--text-2)}
a.stat-card{color:inherit}
a.stat-card:hover{border-color:var(--gold);box-shadow:var(--shadow-md)}

.grid-2{display:grid;grid-template-columns:1fr 1fr;gap:18px}
.grid-3{display:grid;grid-template-columns:repeat(3,1fr);gap:18px}
.grid-wide{display:grid;grid-template-columns:minmax(0,1.6fr) minmax(0,1fr);gap:18px}
.grid-2>.panel,.grid-3>.panel,.grid-wide>.panel{margin-bottom:18px}

/* ---------- Tables ---------- */
.table-wrap{overflow-x:auto;margin:0 -20px -18px}
table{width:100%;border-collapse:collapse;font-size:12.5px}
th{padding:12px 20px;text-align:left;background:#f8fafc;color:var(--text-2);font-size:10.5px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;border-top:1px solid var(--border);border-bottom:1px solid var(--border);white-space:nowrap}
td{padding:14px 20px;border-bottom:1px solid #eef0f3;vertical-align:middle}
tbody tr:hover td{background:#fafbfc}
tbody tr:last-child td{border-bottom:0}
td a{font-weight:600}
.id-link{color:var(--info);font-weight:600}

/* ---------- Badges ---------- */
.badge{display:inline-flex;align-items:center;gap:6px;padding:4px 10px;border-radius:99px;font-size:11px;font-weight:600;white-space:nowrap}
.badge::before{content:"";width:6px;height:6px;border-radius:50%;background:currentColor}
.badge-blue{background:var(--info-bg);color:var(--info)}
.badge-gold{background:var(--warning-bg);color:var(--warning)}
.badge-green{background:var(--success-bg);color:var(--success)}
.badge-gray{background:#f1f3f6;color:#4b5565}
.badge-red{background:var(--danger-bg);color:var(--danger)}

/* ---------- Progress ---------- */
.progress{display:flex;align-items:center;gap:10px;min-width:140px}
.progress>div{flex:1;height:6px;border-radius:6px;background:#eef1f5;overflow:hidden}
.progress>div>span{display:block;height:100%;background:var(--gold);border-radius:6px}
.progress small{font-size:11px;color:var(--text-2);min-width:32px;text-align:right}

/* ---------- Forms ---------- */
.field{margin-bottom:16px;display:flex;flex-direction:column;gap:6px}
.field label{font-size:12px;font-weight:600;color:var(--text)}
input[type=text],input[type=email],input[type=password],input[type=date],input[type=number],input[type=tel],input[type=search],select,textarea{width:100%;height:42px;padding:0 12px;border:1px solid #ccd3dc;border-radius:6px;background:#fff;color:var(--text);font-size:13px;outline:0;transition:.15s}
textarea{height:auto;min-height:100px;padding:10px 12px;resize:vertical}
input[type=file]{font-size:12.5px}
input:focus,select:focus,textarea:focus{border-color:var(--navy);box-shadow:0 0 0 3px rgba(27,54,93,.08)}
input[type=checkbox]{accent-color:var(--navy)}
form.flex input,form.flex select{height:40px}

/* ---------- Alerts ---------- */
.alert{padding:12px 16px;border-radius:6px;margin-bottom:16px;font-size:12.5px;border:1px solid transparent;border-left-width:3px}
.alert-success{background:var(--success-bg);color:var(--success);border-color:#bde8d6}
.alert-error{background:var(--danger-bg);color:var(--danger);border-color:#f5c5ca}
.alert-info{background:var(--info-bg);color:var(--info);border-color:#c9dcf5}

/* ---------- Misc ---------- */
.empty-state{text-align:center;padding:36px 20px;color:var(--text-2);font-size:12.5px}
.muted{color:var(--text-2)}
.small{font-size:11.5px}
.mb-0{margin-bottom:0!important}
.mt-16{margin-top:16px}
.flex{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.flex form{margin:0}
.flex-between{display:flex;align-items:center;justify-content:space-between;gap:10px}
.file-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 0;border-bottom:1px solid #eef0f3}
.file-row:first-child{padding-top:0}
.file-row:last-child{border-bottom:0;padding-bottom:0}
.folder-tag{margin:18px 0 8px;font-size:10.5px;font-weight:700;letter-spacing:.12em;text-transform:uppercase;color:var(--gold-text)}
.tag{color:var(--text-2)}

/* ---------- Dashboard widgets ---------- */
.status-chart{display:flex;align-items:center;justify-content:center;gap:48px;padding:12px 0}
.donut{width:170px;height:170px;border-radius:50%;display:grid;place-items:center;flex:0 0 auto}
.donut>div{width:110px;height:110px;border-radius:50%;background:#fff;display:flex;flex-direction:column;align-items:center;justify-content:center}
.donut strong{font-size:26px;color:var(--navy-deep);line-height:1}
.donut span{margin-top:4px;font-size:9.5px;font-weight:700;letter-spacing:.14em;color:var(--text-2)}
.chart-legend{display:flex;flex-direction:column;gap:12px;min-width:200px}
.chart-legend div{display:flex;align-items:center;gap:10px;font-size:12px}
.chart-legend i{width:9px;height:9px;border-radius:50%}
.chart-legend span{flex:1}
.chart-legend b{color:var(--navy-deep)}
.quick-actions{display:flex;flex-direction:column}
.quick-actions a{display:flex;align-items:center;gap:12px;padding:12px 0;border-bottom:1px solid #eef0f3;color:var(--text);font-size:12.5px}
.quick-actions a:last-child{border-bottom:0}
.quick-actions a>span:first-child{width:34px;height:34px;border-radius:6px;background:#edf2f8;color:var(--navy);display:grid;place-items:center}
.quick-actions a>span:nth-child(2){flex:1}
.quick-actions a:hover{color:var(--navy)}
.quick-actions a .icon:last-child{color:#98a2b3}
.mini-list{display:flex;flex-direction:column}
.mini-list>div,.mini-list>a{display:flex;align-items:center;gap:12px;padding:11px 0;border-bottom:1px solid #eef0f3;color:var(--text)}
.mini-list>*:last-child{border-bottom:0}
.mini-av{width:34px;height:34px;border-radius:50%;background:#edf2f8;color:var(--navy);display:grid;place-items:center;font-size:11px;font-weight:700;flex:0 0 auto}
.mini-list p{margin:0;flex:1;min-width:0}
.mini-list strong,.mini-list small{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.mini-list strong{font-size:12.5px;font-weight:600}
.mini-list small{font-size:11px;color:var(--text-2);margin-top:2px}

/* ---------- Auth (login / forgot / reset) ---------- */
.auth-wrap{min-height:100vh;display:grid;grid-template-columns:44% 56%;background:#fff}
.auth-brand{position:relative;padding:54px 64px;color:#fff;background:var(--navy-deep);overflow:hidden;display:flex;flex-direction:column;justify-content:space-between}
.auth-brand::after{content:"";position:absolute;width:520px;height:520px;top:45%;left:50%;border:1px solid rgba(214,177,94,.1);border-radius:50%;transform:translate(-50%,-50%);box-shadow:0 0 0 80px rgba(214,177,94,.025),0 0 0 160px rgba(214,177,94,.015)}
.auth-brand img{position:relative;z-index:1;width:260px;height:260px;margin:-40px auto 0;object-fit:contain}
.auth-brand>div{position:relative;z-index:1}
.auth-brand .rule{display:block;width:44px;height:2px;background:var(--gold)}
.auth-brand h2{margin:24px 0 14px;color:#fff;font-size:48px;line-height:1.1;letter-spacing:-.04em;font-weight:500}
.auth-brand p{max-width:440px;margin:0;color:#b8c2d0;font-size:15px;line-height:1.6}
.auth-brand address{margin-top:20px;color:#98a7ba;font-size:12px;line-height:1.7;font-style:normal}
.auth-brand a{display:inline-block;margin-top:8px;color:var(--gold-light);font-size:12px}
.auth-brand>small{position:relative;z-index:1;color:#78879d;font-size:10.5px;letter-spacing:.16em}
.auth-card{align-self:center;justify-self:center;width:100%;max-width:440px;padding:60px 24px}
.auth-card .monogram-lg{display:none}
.auth-card .kicker{color:#967226;font-size:10.5px;font-weight:700;letter-spacing:.16em;text-transform:uppercase}
.auth-card h1{margin:12px 0 8px;font-size:34px;letter-spacing:-.035em;font-weight:500;text-align:left}
.auth-card .tag{margin:0 0 26px;font-size:13.5px;text-align:left}
.auth-card .field input{height:48px}
.auth-card .btn{min-height:48px;font-size:13.5px;font-weight:700}
.auth-footer{margin-top:20px;padding-top:16px;border-top:1px solid var(--border);font-size:12.5px;text-align:center;color:var(--text-2)}
.auth-footer a{font-weight:600}
.auth-options{margin:4px 0 18px;display:flex;align-items:center;justify-content:space-between;font-size:12px}
.auth-options label{display:flex;align-items:center;gap:6px;color:var(--text-2)}

@media (max-width:1100px){.grid-wide,.grid-3{grid-template-columns:1fr}.global-search{width:260px}}
@media (max-width:900px){
  .app{grid-template-columns:1fr}.sidebar{position:static;height:auto}.brand{height:110px}.brand img{width:110px;height:110px}
  .sidebar nav{flex-direction:row;flex-wrap:wrap;padding-bottom:10px}.side-user{display:none}
  .grid-2{grid-template-columns:1fr}.global-search{display:none}.content{padding:18px}
  .auth-wrap{grid-template-columns:1fr}.auth-brand{padding:30px}.auth-brand h2{font-size:30px}.auth-brand img{width:150px;height:150px;margin:0 auto}
}
.cards-6{grid-template-columns:repeat(6,minmax(0,1fr))}@media (max-width:1300px){.cards-6{grid-template-columns:repeat(3,1fr)}}

/* ===== v2 module components ===== */
.cards-5{grid-template-columns:repeat(5,minmax(0,1fr))}
@media (max-width:1300px){.cards-5{grid-template-columns:repeat(3,1fr)}}
.summary-strip{display:grid;grid-template-columns:repeat(4,1fr);border:1px solid var(--border);border-radius:var(--radius);background:#fff;margin-bottom:18px;box-shadow:var(--shadow-sm)}
.summary-strip>div{padding:16px 20px;border-right:1px solid var(--border)}
.summary-strip>div:last-child{border-right:0}
.summary-strip strong{display:block;font-size:22px;color:var(--navy-deep);line-height:1.2}
.summary-strip span{font-size:11.5px;color:var(--text-2)}
.toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:0}
.toolbar input[type=date],.toolbar input[type=month],.toolbar select{height:38px}
.search-box{height:38px;min-width:280px;padding:0 12px;border:1px solid #ccd3dc;border-radius:6px;display:flex;align-items:center;gap:8px;color:#8d97a7;background:#fff}
.search-box input{border:0!important;box-shadow:none!important;height:36px!important;padding:0!important;flex:1;min-width:0}
.toggle{display:flex;align-items:center;gap:6px;font-size:12px;color:var(--text-2)}
.tabs{display:flex;gap:4px;border-bottom:1px solid var(--border);margin-bottom:18px;overflow-x:auto;background:#fff;border:1px solid var(--border);border-radius:var(--radius);padding:0 10px}
.tabs a{padding:14px 12px;font-size:12.5px;color:var(--text-2);border-bottom:2px solid transparent;white-space:nowrap;font-weight:500}
.tabs a:hover{color:var(--navy)}
.tabs a.active{color:var(--navy-deep);border-bottom-color:var(--gold);font-weight:600}
.category-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}
@media (max-width:1300px){.category-grid{grid-template-columns:repeat(3,1fr)}}
@media (max-width:900px){.category-grid{grid-template-columns:1fr 1fr}}
.category-card{border:1px solid var(--border);border-radius:var(--radius);padding:14px;display:flex;flex-direction:column;gap:6px;transition:.15s}
.category-card:hover{border-color:var(--gold);box-shadow:var(--shadow-md)}
.category-card__top{display:flex;justify-content:space-between;align-items:flex-start;margin-bottom:6px}
.category-card__top>span:first-child{width:34px;height:34px;border-radius:6px;background:#edf2f8;color:var(--navy);display:grid;place-items:center}
.category-card strong{font-size:13.5px;color:var(--navy-deep)}
.category-card p{margin:0;font-size:11.5px;color:var(--text-2)}
.category-card__actions{display:flex;align-items:center;gap:6px;margin-top:10px;padding-top:10px;border-top:1px solid #eef0f3}
.category-card__actions form{margin:0}
.icon-btn{width:32px;height:32px;border:1px solid #ccd3dc;border-radius:6px;background:#fff;color:var(--navy);display:inline-grid;place-items:center;font-size:12px}
.icon-btn:hover{border-color:var(--navy);color:var(--navy)}
.back-link{display:inline-block;margin-bottom:14px;font-size:12.5px;color:var(--text-2)}
.doc-row{display:grid;grid-template-columns:1fr 130px 34px;gap:8px;margin-bottom:8px;align-items:center}
.timeline{display:flex;gap:0;position:relative}
.tl-step{flex:1;display:flex;flex-direction:column;align-items:center;text-align:center;position:relative;font-size:11px;color:var(--text-2)}
.tl-step::before{content:"";position:absolute;top:7px;left:-50%;right:50%;height:2px;background:#e4e7ec;z-index:0}
.tl-step:first-child::before{display:none}
.tl-step i{width:16px;height:16px;border-radius:50%;background:#fff;border:2px solid #ccd3dc;z-index:1;margin-bottom:8px}
.tl-step.done i{background:var(--success);border-color:var(--success)}
.tl-step.done::before,.tl-step.current::before{background:var(--success)}
.tl-step.current i{background:var(--gold);border-color:var(--gold);box-shadow:0 0 0 4px rgba(214,177,94,.2)}
.tl-step.current span{color:var(--navy-deep);font-weight:600}
.kv-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}
.kv-grid>div{padding:12px;border:1px solid #eef0f3;border-radius:6px;background:#fafbfc;min-width:0}
.kv-grid span{display:block;font-size:10.5px;color:var(--text-2);text-transform:uppercase;letter-spacing:.06em;font-weight:600}
.kv-grid strong{display:block;margin-top:4px;font-size:14px;color:var(--navy-deep);overflow-wrap:anywhere}
.kv-grid small{display:block;font-size:11px;color:var(--text-2)}
.checklist{display:flex;flex-direction:column}
.checklist>div{display:flex;align-items:center;gap:10px;padding:10px 0;border-bottom:1px solid #eef0f3}
.checklist>div:last-child{border-bottom:0}
.checklist p{margin:0;flex:1;font-size:12.5px}
.checklist small{font-size:11px;color:var(--text-2)}
.ck{width:30px;height:30px;border-radius:6px;background:#fff6df;color:#80601d;display:grid;place-items:center;flex:0 0 auto}
.ck.opt{background:#edf2f8;color:var(--navy)}
.review-cell{background:#fafbfc!important;padding:16px 20px!important}
.review-box{display:grid;grid-template-columns:1fr 1.2fr;gap:20px;align-items:start}
.review-box p{margin:4px 0 10px}
.review-form textarea{min-height:64px;margin-bottom:10px}
.inline-form{display:flex;gap:12px;align-items:flex-end;flex-wrap:wrap}
.inline-form .field{margin:0;flex:1;min-width:130px}
.doc-cell{display:flex;align-items:center;gap:8px}
.doc-cell>span{width:28px;height:28px;border-radius:6px;background:#edf2f8;color:var(--navy);display:grid;place-items:center;flex:0 0 auto}
.person{display:flex;align-items:center;gap:10px}
.person strong,.person small{display:block}
.person small{font-size:11px;color:var(--text-2)}
.bar-row{display:grid;grid-template-columns:150px 1fr 90px;gap:12px;align-items:center;padding:7px 0;font-size:12.5px}
.bar-row>div{height:8px;border-radius:6px;background:#eef1f5;overflow:hidden}
.bar-row i{display:block;height:100%;background:var(--gold);border-radius:6px}
.bar-row b{text-align:right;color:var(--navy-deep)}
.pager{display:flex;gap:6px;justify-content:flex-end;margin-top:14px}
.pager a{min-width:32px;height:32px;display:grid;place-items:center;border:1px solid var(--border);border-radius:6px;font-size:12px}
.pager a.active{background:var(--navy);color:#fff;border-color:var(--navy)}
.checkin{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}
.checkin>div{padding:16px;border-radius:8px;background:#f8fafc;border:1px solid #eef0f3}
.checkin span{display:block;font-size:11px;color:var(--text-2);text-transform:uppercase;letter-spacing:.06em}
.checkin strong{display:block;font-size:22px;color:var(--navy-deep);margin-top:4px}
.task-list{display:flex;flex-direction:column}
.task-row{display:flex;align-items:center;gap:12px;padding:12px 0;border-bottom:1px solid #eef0f3}
.task-row:last-child{border-bottom:0}
.task-row form{margin:0}
.task-main{flex:1;min-width:0}
.task-main strong,.task-main small{display:block}
.task-main small{font-size:11px;color:var(--text-2);margin-top:2px}
.task-row.done .task-main strong{text-decoration:line-through;color:#98a2b3}
.check-btn{width:22px;height:22px;border-radius:6px;border:2px solid #ccd3dc;background:#fff;display:grid;place-items:center;color:#fff;padding:0}
.task-row.done .check-btn{background:var(--success);border-color:var(--success)}
.profile-head{display:flex;align-items:center;gap:16px;margin-bottom:20px;padding-bottom:18px;border-bottom:1px solid #eef0f3}
.profile-head strong,.profile-head span,.profile-head small{display:block}
.profile-head strong{font-size:17px;color:var(--navy-deep)}
.profile-head span{font-size:12.5px;color:var(--gold-text);font-weight:600}
.profile-head small{font-size:11px;color:var(--text-2);margin-top:2px}
.av-lg{width:60px;height:60px;border-radius:50%;background:var(--gold-light);color:var(--navy);display:grid;place-items:center;font-weight:700;font-size:18px}
.receipt{max-width:780px;margin:0 auto;background:#fff;border:1px solid var(--border);border-radius:10px;padding:30px;box-shadow:var(--shadow-md)}
.receipt-head{display:flex;gap:16px;align-items:center;padding-bottom:18px;margin-bottom:18px;border-bottom:2px solid var(--gold)}
.receipt-head img{width:72px;height:72px;border-radius:8px;background:var(--navy-deep)}
.receipt-head>div:nth-child(2){flex:1}
.receipt-head strong,.receipt-head span{display:block}
.receipt-head strong{font-size:17px;color:var(--navy-deep)}
.receipt-head span{font-size:11.5px;color:var(--text-2)}
.receipt-no{text-align:right}
.receipt-no span{font-size:10px;letter-spacing:.16em;color:var(--gold-text);font-weight:700}
.receipt-no strong{display:block;font-size:16px}
.receipt-no small{font-size:11px;color:var(--text-2)}
.receipt-amount{margin:18px 0;padding:18px;border-radius:8px;background:var(--navy-deep);color:#fff;display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap}
.receipt-amount span{color:#b8c2d0;font-size:12px}
.receipt-amount strong{font-size:28px;color:var(--gold-light)}
.receipt-amount small{width:100%;color:#b8c2d0}
.receipt-foot{display:flex;justify-content:space-between;margin-top:18px;font-size:11px;color:var(--text-2)}
@media print{
  .sidebar,.topbar,.page-actions,.alert{display:none!important}
  .app{display:block}.content{padding:0}body{background:#fff}
  .receipt{box-shadow:none;border:0}
}
@media (max-width:900px){.kv-grid,.checkin{grid-template-columns:1fr 1fr}.review-box{grid-template-columns:1fr}.summary-strip{grid-template-columns:1fr 1fr}}

/* ===== v3: portal link share ===== */
.share-box{border:1px solid #bde8d6;background:var(--success-bg);border-radius:var(--radius);padding:16px 18px;margin-bottom:18px;display:flex;flex-direction:column;gap:10px}
.share-box strong{display:block;color:var(--navy-deep);font-size:14px}
.share-box span{font-size:12px;color:var(--text-2)}
.share-box small{font-size:11px;color:var(--text-2)}
.share-row{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.share-row input{flex:1;min-width:260px;height:38px;font-size:12px;background:#fff}

/* ===== v5: drafts & OCR ===== */
textarea.mono{font-family:ui-monospace,Menlo,Consolas,monospace;font-size:12px;line-height:1.55}
code{font-family:ui-monospace,Menlo,Consolas,monospace;font-size:11.5px;background:#f1f3f6;padding:1px 5px;border-radius:4px}
.draft-paper{font-family:"Times New Roman",Georgia,serif;font-size:14px;line-height:1.65;color:#111;background:#fff;border:1px solid var(--border);border-radius:6px;padding:28px 32px;box-shadow:inset 0 0 0 6px #fafbfc}
.draft-paper p{margin:0 0 6px;text-align:justify}
.draft-paper .h1{text-align:center;font-weight:700;font-size:17px;margin-bottom:12px}
.draft-paper .h2{font-weight:700;margin-top:10px}
.draft-paper .gap{margin:0;line-height:.6}
.draft-paper .pagebreak{border-top:1px dashed #ccd3dc;margin:16px 0}
.small-paper{font-size:12px;max-height:640px;overflow:auto;padding:20px}
.ocr-box{border:1px solid #c9dcf5;background:var(--info-bg);border-radius:6px;padding:10px 12px;margin:10px 0;font-size:12px}
.ocr-box strong{color:var(--info)}
.kyc-tag{font-size:10px;color:var(--success);font-weight:600}
