:root{--navy:#1C1B4D;--blue:#3E4095;--blue-d:#2F3078;--magenta:#A53692;--line:#E6E5F1;--soft:#F6F5FB;--ink:#1C1B4D;--ink2:#36355E;--muted:#5E5D80;--green:#128C4A;--red:#B42318;--amber:#FFB020}
*{box-sizing:border-box}
body{margin:0;font-family:Inter,system-ui,-apple-system,'Segoe UI',Roboto,sans-serif;color:var(--ink);background:var(--soft);font-size:15px;line-height:1.5}
a{color:var(--blue)}
h1,h2,h3{margin:0;line-height:1.2}
h1{font-size:26px}h2{font-size:18px;margin-bottom:12px}
.muted{color:var(--muted)}.small{font-size:13px}.nowrap{white-space:nowrap}
.shell{display:flex;min-height:100vh}
.side{width:240px;flex:0 0 240px;background:var(--navy);color:#D2D1EE;display:flex;flex-direction:column;padding:20px 14px;position:sticky;top:0;height:100vh;overflow-y:auto}
.side-brand{display:flex;align-items:center;gap:10px;color:#fff;text-decoration:none;font-weight:800;font-size:18px;padding:4px 8px 18px}
.mark{width:36px;height:36px;border-radius:10px;background:#fff;display:inline-flex;align-items:center;justify-content:center;padding:4px}.mark img{width:100%;height:100%}
.side-nav{display:flex;flex-direction:column;gap:2px;flex:1}
.side-nav a{color:#D2D1EE;text-decoration:none;padding:9px 10px;border-radius:8px;display:flex;justify-content:space-between;align-items:center}
.side-nav a:hover{background:#2A2966;color:#fff}
.side-nav a.on{background:#2A2966;box-shadow:inset 3px 0 0 var(--magenta);color:#fff;font-weight:600}
.side-h{font-size:11px;letter-spacing:.1em;text-transform:uppercase;color:#9C9ACB;padding:16px 10px 6px}
.pill{background:var(--magenta);color:#fff;font-size:12px;font-weight:700;border-radius:999px;padding:1px 8px}
.side-logout{display:flex;justify-content:space-between;align-items:center;border-top:1px solid #34337A;padding:14px 8px 0;margin-top:12px;font-size:13px}
.side-logout button{background:none;border:1px solid #5A58A0;color:#D2D1EE;border-radius:8px;padding:6px 10px;cursor:pointer;font:inherit}
.main{flex:1;min-width:0;padding:28px 32px 60px}
.page-head{display:flex;flex-wrap:wrap;gap:12px;justify-content:space-between;align-items:center;margin-bottom:20px}
.count{font-size:15px;font-weight:600;color:var(--muted);background:#fff;border:1px solid var(--line);border-radius:999px;padding:2px 10px;vertical-align:middle}
.card{background:#fff;border:1px solid var(--line);border-radius:14px}
.pad{padding:22px}
.card-head{display:flex;justify-content:space-between;align-items:baseline;margin-bottom:8px}
.btn{display:inline-flex;align-items:center;justify-content:center;gap:6px;background:var(--blue);color:#fff;border:0;border-radius:10px;padding:10px 16px;font:inherit;font-weight:600;text-decoration:none;cursor:pointer;min-height:40px}
.btn:hover{background:var(--blue-d);color:#fff}
.btn-light{background:#fff;color:var(--ink);border:1px solid #CBD3E6}.btn-light:hover{background:var(--soft);color:var(--ink)}
.btn-green{background:var(--green)}.btn-green:hover{background:#0E703B}
.btn-danger{background:#fff;color:var(--red);border:1px solid #F3C6C2}.btn-danger:hover{background:#FEF3F2;color:var(--red)}
.btn-block{width:100%}
.btn-row{display:flex;gap:10px;flex-wrap:wrap;margin-top:16px}
.flash{padding:12px 16px;border-radius:10px;margin-bottom:16px;font-weight:500}
.flash-success{background:#E3F7EC;color:#1E6B43}
.flash-error{background:#FDE8E8;color:#9B1C1C}
.flash-warn{background:#FFF4DC;color:#6B4600}
.toolbar{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin-bottom:14px}
.toolbar input,.toolbar select{font:inherit;padding:9px 12px;border:1px solid #CBD3E6;border-radius:9px;background:#fff;min-height:40px}
.toolbar input[type=search]{min-width:240px}
.inline{display:flex;align-items:center;gap:6px;font-size:13px;color:var(--muted)}
.table-wrap{overflow-x:auto;background:#fff;border:1px solid var(--line);border-radius:14px}
.tbl{width:100%;border-collapse:collapse}
.tbl th{text-align:left;font-size:12px;text-transform:uppercase;letter-spacing:.05em;color:var(--muted);background:var(--soft);padding:11px 14px;white-space:nowrap}
.tbl td{padding:12px 14px;border-top:1px solid var(--line);vertical-align:top}
.tbl a{text-decoration:none}
.tbl-compact td{padding:10px 4px}
.card .tbl-compact tr:first-child td{border-top:0}
.actions{white-space:nowrap;text-align:right}
.actions a{margin-left:12px}
.thumb{height:32px;width:auto;max-width:90px;object-fit:contain;border-radius:4px}
.dot{font-size:12px;font-weight:600;padding:2px 9px;border-radius:999px}
.dot-on{background:#E3F7EC;color:#1E6B43}.dot-off{background:#F1F3F8;color:var(--muted)}
.badge{font-size:12px;font-weight:600;padding:3px 10px;border-radius:999px}
.badge-new{background:#FFF4DC;color:#6B4600}.badge-contacted{background:#ECECF7;color:var(--blue-d)}
.badge-converted{background:#E3F7EC;color:#1E6B43}.badge-closed{background:#F1F3F8;color:var(--muted)}
.form{display:flex;flex-direction:column;gap:14px}
.card.form{padding:24px}
.narrow{max-width:520px}
.form-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(320px,100%),1fr));gap:16px 20px}
.form-grid .fld:has(textarea),.form-grid .form-h{grid-column:1/-1}
.form-h{font-size:14px;text-transform:uppercase;letter-spacing:.08em;color:var(--blue);border-top:1px solid var(--line);padding-top:18px;margin-top:6px}
.form-grid .form-h:first-child{border-top:0;padding-top:0;margin-top:0}
.fld{display:flex;flex-direction:column;gap:6px;font-size:13px;font-weight:600;color:var(--ink2)}
.fld input,.fld select,.fld textarea{font:inherit;font-weight:400;font-size:15px;padding:10px 12px;border:1px solid #CBD3E6;border-radius:9px;background:#fff;color:var(--ink);width:100%}
.fld textarea{resize:vertical;font-family:inherit}
.fld input:focus,.fld select:focus,.fld textarea:focus{outline:2px solid rgba(62,64,149,.25);border-color:var(--blue)}
.help{font-weight:400;color:var(--muted);font-size:12px}
.req{color:var(--red)}
.chk{display:flex;align-items:center;gap:8px;font-weight:600;font-size:14px;color:var(--ink2);padding-top:22px}
.chk input{width:18px;height:18px}
.img-cur{display:flex;align-items:center;gap:14px;margin:4px 0}
.img-cur img{height:64px;width:auto;max-width:160px;object-fit:contain;border:1px solid var(--line);border-radius:8px;background:var(--soft)}
.img-cur .chk{padding-top:0}
.form-actions{display:flex;gap:10px;padding-top:8px}
.sticky-actions{position:sticky;bottom:0;background:var(--soft);padding:14px 0}
.settings-group{margin-bottom:16px}
.children{padding:22px;margin-top:18px}
.child-links{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,1fr));gap:10px}
.child-links a{border:1px solid var(--line);border-radius:10px;padding:12px 14px;text-decoration:none;color:var(--ink);display:flex;flex-direction:column}
.child-links a:hover{border-color:var(--blue)}
.child-links span{color:var(--muted);font-size:13px}
.danger-zone{margin-top:22px}
.stat-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:14px;margin-bottom:18px}
.stat{padding:18px;display:flex;flex-direction:column;text-decoration:none;color:var(--ink)}
.stat span{color:var(--muted);font-size:13px;font-weight:600}
.stat b{font-size:30px}
.two-col{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(420px,100%),1fr));gap:18px;align-items:start}
.type-list{list-style:none;margin:0;padding:0}
.type-list li{display:flex;justify-content:space-between;padding:8px 0;border-top:1px solid var(--line)}
.warn-text{color:#B54708;font-weight:600}
.dl{display:grid;grid-template-columns:120px 1fr;gap:10px 16px;margin:0}
.dl dt{color:var(--muted);font-weight:600;font-size:13px}
.dl dd{margin:0;word-break:break-word}
.pager{display:flex;gap:6px;margin-top:14px;flex-wrap:wrap}
.pager a{padding:6px 12px;border:1px solid var(--line);border-radius:8px;background:#fff;text-decoration:none}
.pager a.on{background:var(--blue);color:#fff;border-color:var(--blue)}
.auth{min-height:100vh;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:24px}
.auth-card{width:100%;max-width:400px;padding:30px;display:flex;flex-direction:column;gap:14px}
.auth-brand{display:flex;align-items:center;gap:10px;font-weight:800;font-size:18px;margin-bottom:6px}
@media (max-width:860px){
  .shell{flex-direction:column}
  .side{width:auto;height:auto;position:static;flex:none}
  .side-nav{flex-direction:row;flex-wrap:wrap}
  .side-h{display:none}
  .main{padding:20px 16px 48px}
  .toolbar input[type=search]{min-width:0;flex:1}
}
.img-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:16px}
.img-slot{border:1px solid var(--line);border-radius:12px;padding:16px;display:flex;flex-direction:column;gap:10px}
.img-prev{height:140px;border-radius:10px;background:var(--soft);display:flex;align-items:center;justify-content:center;overflow:hidden}
.img-prev img{max-height:100%;max-width:100%;object-fit:contain}
.img-form{display:flex;flex-direction:column;gap:8px}
.img-form input[type=file]{font-size:13px;max-width:100%}
.img-slot .btn-danger{width:100%}

/* ===== CRM ===== */
.pill-warn{background:#D92D20;color:#fff}
.side-logout span{display:flex;flex-direction:column;line-height:1.25}
.side-logout small{color:#9C9ACB;font-size:11px}
.tabs{display:flex;gap:4px;flex-wrap:wrap;border-bottom:1px solid var(--line);margin-bottom:14px}
.tabs a{padding:9px 14px;text-decoration:none;color:var(--ink2);font-weight:600;font-size:14px;border-bottom:2px solid transparent;margin-bottom:-1px}
.tabs a:hover{color:var(--blue)}
.tabs a.on{color:var(--blue);border-bottom-color:var(--magenta)}
.pipeline{display:grid;grid-template-columns:repeat(auto-fit,minmax(110px,1fr));gap:8px;margin-bottom:14px}
.pipeline a{background:#fff;border:1px solid var(--line);border-radius:12px;padding:10px 12px;text-decoration:none;color:var(--ink);display:flex;flex-direction:column;gap:2px;border-top:3px solid #CFCDE3}
.pipeline a span{font-size:12px;color:var(--muted);font-weight:600;line-height:1.25}
.pipeline a b{font-size:20px}
.pipeline a.on{border-color:var(--blue);box-shadow:0 0 0 2px rgba(62,64,149,.15)}
.pl-new{border-top-color:#F5B000!important}.pl-contacted{border-top-color:#4F8BE6!important}.pl-interested{border-top-color:#7B5BD6!important}
.pl-demo_scheduled{border-top-color:#A53692!important}.pl-demo_done{border-top-color:#C2559F!important}.pl-follow_up{border-top-color:#E07A5F!important}
.pl-enrolled{border-top-color:#128C4A!important}.pl-lost{border-top-color:#98A2B3!important}
.st-new{background:#FFF4DC;color:#6B4600}.st-contacted{background:#E5EEFC;color:#1E4FA3}.st-interested{background:#EEE8FB;color:#4A2EA0}
.st-demo_scheduled{background:#F8EAF5;color:#7D2470}.st-demo_done{background:#F5E4F0;color:#8E2D74}.st-follow_up{background:#FDEDE8;color:#9A3412}
.st-enrolled{background:#E3F7EC;color:#1E6B43}.st-lost{background:#F1F3F8;color:#5E5D80}
.pr-hot{background:#FDE8E8;color:#B42318}.pr-cold{background:#E4F1FB;color:#1F5F8B}
.role-admin{background:#1C1B4D;color:#fff}.role-manager{background:#ECECF7;color:#2F3078}.role-counsellor{background:#F8EAF5;color:#7D2470}
.fu-over{color:#B42318;font-weight:600}.fu-today{color:#B54708;font-weight:600}
.leads-tbl tr.is-new td:first-child{box-shadow:inset 3px 0 0 #F5B000}
.leads-tbl td{vertical-align:middle}
.bulkbar{display:flex;flex-wrap:wrap;gap:8px;align-items:center;background:#fff;border:1px solid var(--line);border-radius:12px;padding:8px 12px;margin-bottom:10px}
.bulkbar select{font:inherit;padding:8px 10px;border:1px solid #CBD3E6;border-radius:9px;background:#fff}
.lead-head{display:flex;flex-wrap:wrap;justify-content:space-between;gap:16px;align-items:flex-end;margin-bottom:18px}
.lead-head h1{margin:6px 0 8px}
.lead-sub{display:flex;flex-wrap:wrap;gap:8px 18px;align-items:center;font-size:14px}
.lead-grid{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:18px;align-items:start}
.lead-main,.lead-side{display:flex;flex-direction:column;gap:18px;min-width:0}
@media (max-width:1100px){.lead-grid{grid-template-columns:1fr}}
.form-grid.g3{grid-template-columns:repeat(auto-fill,minmax(min(200px,100%),1fr))}
.form-grid.g2{grid-template-columns:repeat(2,minmax(0,1fr))}
@media (max-width:520px){.form-grid.g2{grid-template-columns:1fr}}
.lead-side select{font:inherit;padding:10px 12px;border:1px solid #CBD3E6;border-radius:9px;background:#fff;width:100%}
.fu-row{display:flex;flex-direction:column;gap:8px}
.fu-row input[type=datetime-local],.fld input[type=datetime-local]{max-width:280px}
.fu-quick{display:flex;flex-wrap:wrap;gap:6px}
.chip{font:inherit;font-size:13px;font-weight:600;background:#ECECF7;color:#2F3078;border:0;border-radius:999px;padding:6px 12px;cursor:pointer}
.chip:hover{background:#DCDCF2}
.timeline{list-style:none;margin:0;padding:0;display:flex;flex-direction:column}
.timeline li{display:grid;grid-template-columns:34px 1fr;gap:12px;padding:12px 0;border-top:1px solid var(--line)}
.timeline li:first-child{border-top:0}
.tl-ico{width:34px;height:34px;border-radius:10px;background:var(--soft);display:flex;align-items:center;justify-content:center;font-size:15px}
.tl-call .tl-ico{background:#E5EEFC}.tl-whatsapp .tl-ico{background:#E3F7EC}.tl-stage .tl-ico{background:#F8EAF5;color:#7D2470;font-weight:800}
.tl-assigned .tl-ico,.tl-followup .tl-ico{background:#FFF4DC}
.tl-stage .tl-head,.tl-assigned .tl-head,.tl-followup .tl-head{color:var(--muted)}
.tl-body{margin-top:4px;white-space:normal;color:var(--ink2)}
.warn-card{border-color:#F5C26B;background:#FFFBF0}
.dup-list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:10px}
.stat-over b{color:#B42318}.stat-won b{color:#128C4A}
[hidden]{display:none!important}

/* ===== Reports & import (v3) ===== */
.rpt-bar{display:flex;flex-wrap:wrap;gap:10px 16px;align-items:center;justify-content:space-between;margin-bottom:16px}
.seg{display:flex;flex-wrap:wrap;background:#fff;border:1px solid var(--line);border-radius:10px;padding:3px;gap:2px}
.seg a{padding:7px 12px;border-radius:8px;text-decoration:none;color:var(--ink2);font-weight:600;font-size:13px}
.seg a.on{background:var(--blue);color:#fff}
.stat small{font-size:12px;margin-top:2px}
.won{color:#128C4A}
.rpt-tbl th{white-space:normal;font-size:11px;line-height:1.3}
.rpt-tbl td{white-space:nowrap}
.total-row td{background:var(--soft);border-top:2px solid var(--line)}
.daily td{padding:6px 8px}
.bar{display:block;height:10px;border-radius:6px;background:linear-gradient(90deg,#3E4095,#A53692);min-width:2px}
.funnel{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:8px}
.funnel li{display:grid;grid-template-columns:170px 1fr 40px;gap:10px;align-items:center}
.f-bar{height:12px;background:var(--soft);border-radius:6px;overflow:hidden}
.f-bar i{display:block;height:100%;border-radius:6px;background:#CFCDE3;border-top:0!important}
.f-bar i.pl-new{background:#F5B000}.f-bar i.pl-contacted{background:#4F8BE6}.f-bar i.pl-interested{background:#7B5BD6}.f-bar i.pl-demo_scheduled{background:#A53692}.f-bar i.pl-demo_done{background:#C2559F}.f-bar i.pl-follow_up{background:#E07A5F}.f-bar i.pl-enrolled{background:#128C4A}.f-bar i.pl-lost{background:#98A2B3}
.funnel b{text-align:right}
.role-team_lead{background:#E3F7EC;color:#1E6B43}
.sub-h{font-size:14px;margin:0 0 8px}
.confirm-bar{display:flex;flex-wrap:wrap;gap:12px;align-items:center;justify-content:space-between;background:#E3F7EC;border-radius:12px;padding:14px 16px;margin-top:16px}
.confirm-bar span{flex:1 1 320px;font-size:14px;color:#1E6B43}
.tl-import .tl-ico{background:#ECECF7}
@media (max-width:520px){.funnel li{grid-template-columns:120px 1fr 32px}}
.btn:disabled,.btn[disabled]{opacity:.45;cursor:not-allowed}

/* ===== Report sharing & print ===== */
.share-bar{display:flex;flex-wrap:wrap;gap:8px;align-items:center;background:#fff;border:1px solid var(--line);border-radius:12px;padding:10px 12px;margin-bottom:16px}
.share-l{font-weight:700;font-size:14px;margin-right:6px}
.visually-hidden{position:absolute!important;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:pre}
.print-only{display:none}
.side-ver{font-size:11px;color:#7C7AB0;padding:10px 8px 0}
@media print{
  @page{size:A4 landscape;margin:12mm}
  body{background:#fff;font-size:11px}
  .side,.rpt-bar,.share-bar,.flash,.page-head .btn,.page-head a.muted{display:none!important}
  .shell{display:block}.main{padding:0}
  .print-only{display:flex!important}
  .print-head{align-items:center;gap:14px;border-bottom:2px solid #3E4095;padding-bottom:8px;margin-bottom:12px;font-size:12px;color:#36355E}
  .card{box-shadow:none;break-inside:avoid}
  .stat-grid{grid-template-columns:repeat(6,1fr)}
  .two-col{grid-template-columns:1fr 1fr}
  .table-wrap{overflow:visible!important;max-height:none!important}
  .bar,.f-bar i{-webkit-print-color-adjust:exact;print-color-adjust:exact}
  .badge,.st-new,.st-enrolled{-webkit-print-color-adjust:exact;print-color-adjust:exact}
  a{color:inherit;text-decoration:none}
}

/* Website access (team form) + change log */
.content-access{border:1px solid var(--line,#E3E6EF);border-radius:12px;padding:12px 14px 14px;margin:14px 0}
.content-access legend{font-weight:700;font-size:14px;padding:0 6px}
.chk-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:2px 12px;margin-bottom:6px}
.content-access .chk{padding-top:8px;font-weight:500}
.badge-del{background:#FDECEC;color:#9B1C1C}
.log-filters{display:flex;flex-wrap:wrap;gap:10px;align-items:center}
.log-filters select{min-width:180px}

/* Reports: "Leads handled" emphasis + handled-leads list */
.rpt-tbl .col-hl,.daily .col-hl{background:rgba(62,64,149,.06)}
.stat-hl{box-shadow:inset 0 0 0 2px rgba(62,64,149,.35)}
.badge-old{background:#EEF0FB;color:#3E4095}
.handled .remark-cell{max-width:280px;white-space:normal}
@media print{.handled-wrap,.table-wrap{max-height:none!important;overflow:visible!important}}

/* Daily work report card */
.day-card{margin-bottom:18px;border:2px solid rgba(62,64,149,.25)}
.day-head{display:flex;flex-wrap:wrap;gap:12px;justify-content:space-between;align-items:flex-start;margin-bottom:14px}
.day-head h2{margin:0}
.day-btns{display:flex;flex-wrap:wrap;gap:8px}
.day-sum{display:grid;grid-template-columns:repeat(6,1fr);gap:10px;margin-bottom:14px}
.day-sum>div{background:#F6F7FB;border-radius:10px;padding:10px 12px;display:flex;flex-direction:column}
.day-sum>div:first-child{background:#EEF0FB}
.day-sum span{font-size:12px;color:var(--muted,#5B5F7A)}
.day-sum b{font-size:22px;line-height:1.2}
.day-sum small{font-size:11px;color:var(--muted,#7A7E96)}
.day-tbl .remark-cell{max-width:300px;white-space:normal}
.day-pend{margin:10px 0 0;color:#B42318}
@media (max-width:900px){.day-sum{grid-template-columns:repeat(3,1fr)}}
@media (max-width:520px){.day-sum{grid-template-columns:repeat(2,1fr)}.day-btns .btn{flex:1 1 100%}}
@media print{.day-btns{display:none}}
.day-narrow{max-width:620px}
.day-tbl tr.sub td{color:var(--muted,#5B5F7A);font-size:13px;padding-top:4px;padding-bottom:4px}
.day-tbl tr.sub td:first-child{padding-left:28px}
.day-narrow .day-tbl td:last-child,.day-narrow .day-tbl th:last-child{text-align:right;font-weight:700;width:30%}
.day-narrow .day-tbl tr.sub td:last-child{font-weight:500}
.day-msg{margin:10px 0 0;padding:8px 12px;background:#EEF7F1;border-radius:8px;color:#14532D}

/* Finance: admissions, payments, collections */
.flash-info{background:#ECECF7;color:#2F3078}
.badge-warn{background:#FFF4DC;color:#6B4600}.badge-ok{background:#E3F7EC;color:#1E6B43}
.num{text-align:right}
.due{color:#B42318}
.chip.on{background:#3E4095;color:#fff}
a.chip{text-decoration:none;display:inline-block}
.btn-sm{min-height:0;padding:6px 14px;font-size:13px}
.form-grid.g4{grid-template-columns:repeat(auto-fill,minmax(min(170px,100%),1fr))}
.fin-form h2{margin:18px 0 8px;font-size:16px}.fin-form h2:first-of-type{margin-top:0}
.fin-total{font-size:22px;font-weight:700;color:#1E1F4B;padding:6px 0}
.fin-stats{margin-bottom:18px}
.fin-acts{white-space:nowrap}.fin-acts form{display:inline-block;margin:0 4px 4px 0}
.fin-more{display:inline-block;vertical-align:top}.fin-more summary{cursor:pointer;font-size:13px;color:#9B1C1C;padding:6px 4px;list-style:none}
.fin-more summary::-webkit-details-marker{display:none}
.fin-more form{display:flex;gap:6px;margin-top:6px}.fin-more input{min-width:180px}
.fin-edit summary{cursor:pointer}.fin-edit form{margin-top:12px}
.fin-log{list-style:none;margin:0;padding:0}.fin-log li{padding:7px 0;border-bottom:1px solid #EEF0F6;font-size:13.5px}
.tbl.kv td:last-child{text-align:right;white-space:nowrap}
.tbl tr.tot td{border-top:2px solid #3E4095;background:#F6F7FB}
.fin-lead.fin-lead-hl{box-shadow:inset 0 0 0 2px #3E4095}
.fin-adm-mini{display:flex;flex-direction:column;gap:2px;padding:10px 12px;margin-bottom:10px;border-radius:10px;background:#F6F7FB;color:inherit;text-decoration:none}
.fin-adm-mini:hover{background:#ECECF7}
.fin-st .fin-acts{margin-top:6px;white-space:normal}
.fin-st{min-width:200px}
/* Finance phase 2 */
.fin-add summary{cursor:pointer}.fin-add[open] summary{margin-bottom:12px}
.tbl.kv-left td:first-child{color:var(--muted,#5B5F7A);width:34%}.tbl.kv-left td:last-child{text-align:left;white-space:normal}
.inline-form{display:inline-flex;gap:8px;align-items:center;flex-wrap:wrap;margin:0}
.pnl td{padding:9px 10px}.pnl .pnl-h td{font-weight:700}.pnl .pnl-i{padding-left:26px}
.pnl .pnl-t td{border-top:2px solid #3E4095;font-size:17px;font-weight:800;background:#F6F7FB}
.pnl-months tr.closed td{background:#FAFAFC}
.bar.bar-neg{background:#E5484D}
.pnl-grid{align-items:start}
.day-tbl tr.strong td{font-weight:700;border-top:2px solid #3E4095;background:#F6F7FB}
/* Month-end report */
.me-cards .day-card{margin-bottom:18px}
.me-h{margin:26px 0 12px;font-size:20px}
.me-sec{margin-bottom:18px}.me-sec h3{margin:0 0 12px;font-size:16px}
.tbl tr.me-cat td{background:#F4F5FB}
@media print{.me-sec,.day-card{break-inside:avoid}.toolbar{display:none}}

/* Lead ownership: backup pool + lead requests */
.bk-tag{background:#EEF0F4;color:#475467}
.dup-action{margin:0 0 18px;max-width:720px;border-color:#F5C26B;background:#FFFBF0}
.req-row{display:flex;gap:16px;justify-content:space-between;align-items:flex-start;padding:14px 0;border-top:1px solid var(--line,#E4E7EC)}
.req-row:first-of-type{border-top:0}
.req-act{display:flex;gap:8px;flex-wrap:wrap;align-items:center;justify-content:flex-end;max-width:420px}
.req-act input{min-width:180px;flex:1}
@media (max-width:760px){.req-row{flex-direction:column}.req-act{justify-content:flex-start;max-width:none}}

/* Students: ticket thread + attendance grid */
.sp-thread{display:flex;flex-direction:column;gap:12px;margin:0 0 16px}
.sp-msg{background:#fff;border:1px solid var(--line);border-radius:14px;padding:14px 16px}
.sp-msg p{margin:6px 0 0}
.sp-msg-h{display:flex;justify-content:space-between;gap:10px}
.sp-msg-student{background:#EEF0FB;border-color:#D9DCF3;margin-right:12%}
.sp-msg-staff{border-left:4px solid var(--magenta);margin-left:12%}
.sp-msg-internal{background:#FFF8E6;border-color:#F5D58A;border-left-color:#E0A21B}
.sp-msg-system{background:transparent;border-style:dashed;font-size:13px;padding:8px 14px}
.att-grid th.num a{text-decoration:none;color:inherit;font-size:12px;line-height:1.2;display:block}
.att-grid td.num{font-weight:700;font-size:13px}
.att-grid .g-p{background:#E7F6EC;color:#11733F}.att-grid .g-l{background:#FFF4DB;color:#8A5A00}
.att-grid .g-a{background:#FDECEA;color:#B42318}.att-grid .g-e{background:#F0F0F5;color:#5E5D80}
.rp-remark{border-left:3px solid var(--magenta);padding:2px 0 2px 12px}
.rp-remark p{margin:0 0 2px}
details.card summary{cursor:pointer}
details.card[open] summary{margin-bottom:14px}
.tbl select,.tbl input[type=text],.tbl input:not([type]){min-height:34px;border:1px solid var(--line);border-radius:8px;padding:4px 8px;font:inherit;font-size:13px;background:#fff;max-width:100%}

/* WhatsApp panel */
.wa-panel{border-top:4px solid #25D366}
.wa-thread{max-height:420px;overflow-y:auto;background:#EFEAE2;border-radius:12px;padding:12px;display:flex;flex-direction:column;gap:8px;margin-bottom:12px}
.wa-msg{max-width:78%;padding:8px 10px 6px;border-radius:10px;font-size:14px;line-height:1.45;box-shadow:0 1px 1px rgba(0,0,0,.06);word-wrap:break-word}
.wa-in{background:#fff;align-self:flex-start;border-top-left-radius:2px}
.wa-out{background:#D9FDD3;align-self:flex-end;border-top-right-radius:2px}
.wa-meta{font-size:11px;color:#667781;margin-top:3px;text-align:right}
.wa-tag{font-size:11px;color:#667781;margin-bottom:2px}
.wa-st{font-weight:700}.wa-read{color:#53BDEB}.wa-fail{color:#B42318}
.wa-err{font-size:12px;color:#B42318;margin-top:2px}
.wa-open{color:#11733F;font-weight:600;margin:0 0 6px}.wa-closed{color:#8A5A00;margin:0 0 6px}
.wa-compose textarea{width:100%;border:1px solid var(--line);border-radius:10px;padding:10px;font:inherit}
.wa-tpl-box summary{cursor:pointer;font-weight:600;margin:8px 0}
.wa-preview{background:#D9FDD3;border-radius:10px;padding:10px 12px;font-size:14px;line-height:1.5;margin:8px 0;white-space:normal}
.wa-btns{display:flex;flex-wrap:wrap;gap:6px;margin:6px 0}
.wa-btns span{background:#fff;border:1px solid #CFE9D3;color:#0B7A55;border-radius:8px;padding:4px 10px;font-size:13px;font-weight:600}
.wa-from{max-width:420px}
