:root{--ink:#172033;--muted:#667085;--line:#e7ebf3;--bg:#f4f6fb;--card:#fff;--brand:#2563eb;--brand2:#60a5fa;--deep:#101828;--soft:#eff6ff;--ok:#10805c;--warn:#1d4ed8;--danger:#b42318;--blue:#2357d8}*{box-sizing:border-box}body{margin:0;background:radial-gradient(circle at top left,#eff6ff 0,#f4f6fb 34%,#eef2f7 100%);color:var(--ink);font-family:Inter,system-ui,-apple-system,"Segoe UI",Arial,sans-serif}.app-shell{display:flex;min-height:100vh}.sidebar{width:282px;background:linear-gradient(180deg,#111827 0%,#172033 58%,#0b1220 100%);color:#fff;position:fixed;inset:0 auto 0 0;padding:22px 18px;z-index:1000;box-shadow:18px 0 45px rgba(16,24,40,.14);display:flex;flex-direction:column}.brand{display:flex;align-items:center;gap:12px;padding:12px 10px 22px;border-bottom:1px solid rgba(255,255,255,.10);margin-bottom:14px}.brand-mark{width:46px;height:46px;border-radius:16px;background:linear-gradient(135deg,#93c5fd,#1d4ed8);display:flex;align-items:center;justify-content:center;color:#fff;font-weight:800;box-shadow:0 12px 24px rgba(37,99,235,.28);overflow:hidden}.brand-mark img{width:100%;height:100%;object-fit:contain;background:#fff}.brand strong{display:block;font-size:15px;line-height:1.2}.brand span{display:block;color:#aab4c5;font-size:12px;margin-top:3px}.sidebar-nav{overflow:auto;padding-right:4px}.sidebar-nav a,.logout-link{display:flex;align-items:center;gap:10px;color:#d7deea;text-decoration:none;padding:12px 13px;border-radius:14px;margin:3px 0;font-size:14px;transition:.18s ease}.sidebar-nav a span{width:24px;height:24px;border-radius:10px;background:rgba(255,255,255,.08);display:inline-flex;align-items:center;justify-content:center;font-size:12px}.sidebar-nav a:hover,.sidebar-nav a.active{background:linear-gradient(135deg,rgba(37,99,235,.22),rgba(30,64,175,.42));color:#fff;transform:translateX(3px)}.sidebar-nav a.active span{background:#2563eb;color:#111827}.logout-link{margin-top:auto;background:rgba(255,255,255,.06);justify-content:center}.main{margin-left:282px;width:calc(100% - 282px);min-height:100vh}.topbar{height:82px;background:rgba(255,255,255,.82);backdrop-filter:blur(12px);border-bottom:1px solid rgba(231,235,243,.9);display:flex;align-items:center;justify-content:space-between;padding:0 30px;position:sticky;top:0;z-index:20}.eyebrow{text-transform:uppercase;letter-spacing:.12em;color:#2563eb;font-weight:700;font-size:11px}.topbar h5{font-weight:800;color:#152238}.topbar-user{background:#fff;border:1px solid var(--line);border-radius:999px;padding:8px 16px;text-align:right;box-shadow:0 8px 24px rgba(16,24,40,.05)}.topbar-user span{display:block;font-weight:700;font-size:13px}.topbar-user small{display:block;color:var(--muted);font-size:11px}.content{padding:30px}.page-hero{display:flex;align-items:flex-end;justify-content:space-between;gap:18px;margin-bottom:22px}.page-hero h2,.page-hero h3{font-weight:850;letter-spacing:-.03em;margin:0}.page-hero p{color:var(--muted);margin:6px 0 0}.card{border:1px solid rgba(231,235,243,.85);border-radius:24px;box-shadow:0 18px 50px rgba(16,24,40,.08);background:rgba(255,255,255,.92)}.card-body{padding:24px}.stat-card{position:relative;overflow:hidden;padding:24px;min-height:138px}.stat-card:after{content:"";position:absolute;right:-36px;top:-36px;width:120px;height:120px;border-radius:50%;background:linear-gradient(135deg,rgba(37,99,235,.24),rgba(35,87,216,.12))}.stat-card small{color:var(--muted);font-weight:700;text-transform:uppercase;letter-spacing:.08em;font-size:11px}.stat-card h3{font-size:34px;font-weight:850;margin:10px 0 0}.workflow-card{background:linear-gradient(135deg,#172033,#2b364d);color:#fff}.workflow-card p{color:#d7deea}.btn{border-radius:13px;font-weight:700;padding:.64rem 1rem}.btn-primary{background:linear-gradient(135deg,#2563eb,#60a5fa);border:0;box-shadow:0 10px 24px rgba(37,99,235,.22)}.btn-outline-primary{border-color:#2563eb;color:#1d4ed8}.btn-outline-primary:hover{background:#1d4ed8;border-color:#1d4ed8}.form-control,.form-select{border-radius:14px;border:1px solid #d9e0ea;padding:.72rem .85rem}.form-control:focus,.form-select:focus{border-color:#2563eb;box-shadow:0 0 0 .22rem rgba(37,99,235,.16)}.form-label,label{font-weight:700;color:#344054;margin-bottom:7px}.table{margin:0}.table>:not(caption)>*>*{padding:15px 16px;border-bottom-color:#eef1f6;vertical-align:middle}.table th{font-size:12px;text-transform:uppercase;letter-spacing:.08em;color:#667085;background:#f8fafc}.badge-soft{border-radius:999px;padding:7px 11px;font-weight:800;font-size:12px}.status-draft{background:#f2f4f7;color:#344054}.status-sent{background:#eff6ff;color:#2357d8}.status-approved{background:#ecfdf3;color:#10805c}.status-changes_requested{background:#eff6ff;color:#1d4ed8}.status-rejected{background:#fef3f2;color:#b42318}.upload-zone{border:2px dashed #bfdbfe;background:linear-gradient(135deg,#eff6ff,#fff);border-radius:22px;padding:28px;text-align:center;min-height:170px;display:flex;flex-direction:column;justify-content:center}.upload-zone .icon{font-size:38px;color:#2563eb;margin-bottom:8px}.upload-zone small{color:var(--muted)}.form-panel{padding:26px}.section-title{font-size:15px;font-weight:850;text-transform:uppercase;letter-spacing:.08em;color:#2563eb;margin:4px 0 18px}.quick-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}.quick-action{display:block;text-decoration:none;background:#fff;border:1px solid var(--line);border-radius:20px;padding:20px;color:#172033;box-shadow:0 12px 30px rgba(16,24,40,.05)}.quick-action:hover{transform:translateY(-2px);color:#1d4ed8}.login-page{min-height:100vh;display:flex;align-items:center;justify-content:center;background:linear-gradient(135deg,#101828,#27344c)}.login-card{width:410px;background:#fff;border-radius:28px;box-shadow:0 25px 80px rgba(0,0,0,.28);padding:38px}.invoice-box{background:#fff;border-radius:24px;padding:34px;box-shadow:0 18px 50px rgba(16,24,40,.08)}.invoice-actions{display:flex;gap:8px;flex-wrap:wrap}.item-total-bar{background:#eff6ff;border:1px solid #bfdbfe;border-radius:18px;padding:18px}.mws-mobile-menu-btn{display:none;position:fixed;top:18px;left:18px;z-index:1100;border:0;background:#172033;color:#fff;border-radius:14px;width:46px;height:46px;box-shadow:0 12px 28px rgba(16,24,40,.25)}.mws-mobile-overlay{display:none;position:fixed;inset:0;background:rgba(16,24,40,.55);z-index:900}.mws-alert{border-radius:16px;border:0}@media(max-width:1200px){.quick-grid{grid-template-columns:repeat(2,1fr)}}@media(max-width:991px){.mws-mobile-menu-btn{display:block}.sidebar{transform:translateX(-105%);transition:.22s ease;width:286px}.mws-menu-open .sidebar{transform:translateX(0)}.mws-menu-open .mws-mobile-overlay{display:block}.main{margin-left:0;width:100%}.topbar{padding-left:78px}.content{padding:22px}.page-hero{display:block}.topbar-user{display:none}}@media(max-width:640px){.quick-grid{grid-template-columns:1fr}.content{padding:18px}.card-body,.form-panel{padding:18px}.topbar h5{font-size:16px}.stat-card h3{font-size:28px}}@media print{@page{size:A4;margin:12mm}body{background:#fff!important}.sidebar,.topbar,.invoice-actions,.no-print,.mws-mobile-menu-btn{display:none!important}.main{margin-left:0!important;width:100%!important}.content{padding:0!important}.invoice-box,.card{box-shadow:none!important;border:0!important}}


/* v0.5 form polish */
.form-panel,.invoice-form{padding:28px 30px;}
.form-panel .row,.invoice-form .row{align-items:flex-start;}
.mws-form-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px 20px;}
.mws-form-grid .full{grid-column:1/-1;}
.mws-form-grid .wide{grid-column:span 2;}
.field-card{background:#fbfcff;border:1px solid #edf1f7;border-radius:18px;padding:16px;}
.field-card label{font-size:13px;color:#344054;}
.form-control,.form-select{min-height:50px;background:#fff;}
textarea.form-control{min-height:118px;}
.form-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:24px;padding-top:20px;border-top:1px solid #edf1f7;}
.invoice-item-row{background:#fbfcff;border:1px solid #edf1f7;border-radius:18px;padding:12px;margin-bottom:12px!important;}
.customer-profile-card{background:linear-gradient(135deg,#172033,#2b364d);color:#fff;border-radius:24px;padding:26px;box-shadow:0 18px 50px rgba(16,24,40,.12)}
.customer-profile-card small{color:#cbd5e1;display:block;margin-top:4px}.timeline-list{border-left:2px solid #bfdbfe;margin-left:10px;padding-left:20px}.timeline-item{position:relative;margin-bottom:18px}.timeline-item:before{content:"";position:absolute;left:-28px;top:6px;width:12px;height:12px;border-radius:50%;background:#2563eb;border:3px solid #fff;box-shadow:0 0 0 2px #bfdbfe}.pill-action{border-radius:999px;padding:.45rem .8rem;font-weight:700;font-size:12px}
@media(max-width:1100px){.mws-form-grid{grid-template-columns:repeat(2,minmax(0,1fr));}.mws-form-grid .wide{grid-column:1/-1}}
@media(max-width:700px){.mws-form-grid{grid-template-columns:1fr}.form-actions{flex-direction:column}.form-actions .btn{width:100%}}

/* v0.6 universal premium form layout for remaining raw entry screens */
.content > h3,
.content > h2{
  font-weight:850;
  letter-spacing:-.03em;
  margin:0 0 18px;
  color:#172033;
}
form.row.g-3.card.card-body{
  display:grid !important;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:20px 22px !important;
  padding:30px !important;
  border-radius:26px !important;
  border:1px solid rgba(231,235,243,.9) !important;
  box-shadow:0 22px 55px rgba(16,24,40,.08) !important;
  background:rgba(255,255,255,.96) !important;
  margin:0 !important;
}
form.row.g-3.card.card-body > [class*="col-"]{
  width:auto !important;
  max-width:none !important;
  flex:none !important;
  padding:0 !important;
}
form.row.g-3.card.card-body > .col-12,
form.row.g-3.card.card-body > .col-md-12{
  grid-column:1/-1 !important;
}
form.row.g-3.card.card-body .col-md-8,
form.row.g-3.card.card-body .col-lg-8{
  grid-column:span 2 !important;
}
form.row.g-3.card.card-body .form-label{
  display:block;
  font-size:13px;
  font-weight:800;
  color:#344054;
  margin-bottom:8px;
}
form.row.g-3.card.card-body .form-control,
form.row.g-3.card.card-body .form-select{
  min-height:52px;
  border-radius:15px;
  border:1px solid #d9e0ea;
  background:#fff;
  box-shadow:0 1px 0 rgba(16,24,40,.02);
}
form.row.g-3.card.card-body textarea.form-control{
  min-height:126px;
  resize:vertical;
}
form.row.g-3.card.card-body .col-12:last-child{
  display:flex;
  justify-content:flex-end;
  gap:10px;
  border-top:1px solid #edf1f7;
  padding-top:22px !important;
  margin-top:6px;
}
form.row.g-3.card.card-body .btn{
  min-width:118px;
}
form.row.g-3.card.card-body .btn:not(.btn-primary){
  background:#fff;
  border:1px solid #edf1f7;
  color:#172033;
}
/* Make long text areas feel intentional */
form.row.g-3.card.card-body textarea[name="address"],
form.row.g-3.card.card-body textarea[name="description"],
form.row.g-3.card.card-body textarea[name="notes"],
form.row.g-3.card.card-body textarea[name="issues_found"],
form.row.g-3.card.card-body textarea[name="contractor_remarks"],
form.row.g-3.card.card-body textarea[name="next_action"]{
  min-height:132px;
}
@media(max-width:1180px){
  form.row.g-3.card.card-body{grid-template-columns:repeat(2,minmax(0,1fr));}
  form.row.g-3.card.card-body .col-md-8,
  form.row.g-3.card.card-body .col-lg-8{grid-column:1/-1 !important;}
}
@media(max-width:720px){
  form.row.g-3.card.card-body{grid-template-columns:1fr;padding:20px !important;}
  form.row.g-3.card.card-body .col-12:last-child{flex-direction:column;}
  form.row.g-3.card.card-body .btn{width:100%;}
}
.form-select{
  appearance:auto !important;
  -webkit-appearance:menulist !important;
  background-color:#fff !important;
}
.invoice-item-row{background:#fbfcff;border:1px solid #edf1f7;border-radius:18px;padding:12px;margin-bottom:12px !important;}
.form-card{border:0;border-radius:26px;padding:28px;box-shadow:0 24px 70px rgba(15,23,42,.08);background:#fff;}
.form-actions{display:flex;gap:12px;justify-content:flex-end;border-top:1px solid #edf1f7;margin-top:22px;padding-top:22px;}
.info-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;}
.info-grid>div{background:#fbfcff;border:1px solid #edf1f7;border-radius:18px;padding:16px;display:flex;flex-direction:column;gap:4px;}
.info-grid label,.view-card label{font-size:12px;text-transform:uppercase;letter-spacing:.06em;color:#64748b;font-weight:700;}
.info-grid strong{font-size:16px;color:#0f172a;}
.info-grid small{color:#64748b;}
.note-box{min-height:120px;background:#fbfcff;border:1px solid #edf1f7;border-radius:18px;padding:16px;color:#0f172a;}
@media(max-width:900px){.info-grid{grid-template-columns:1fr}.form-actions{flex-direction:column}.form-actions .btn{width:100%;}}

/* Premium scrollbar and sidebar refinement */
html{
  scrollbar-width:thin;
  scrollbar-color:#2563eb #e5e7eb;
  scroll-behavior:smooth;
}
body{
  overflow-x:hidden;
}
::-webkit-scrollbar{
  width:8px;
  height:8px;
}
::-webkit-scrollbar-track{
  background:#e5e7eb;
  border-radius:999px;
}
::-webkit-scrollbar-thumb{
  background:linear-gradient(180deg,#60a5fa,#2563eb,#1d4ed8);
  border-radius:999px;
  border:2px solid #e5e7eb;
}
::-webkit-scrollbar-thumb:hover{
  background:linear-gradient(180deg,#93c5fd,#2563eb,#1e40af);
}
.sidebar{
  width:268px;
  padding:20px 16px;
}
.main{
  margin-left:268px;
  width:calc(100% - 268px);
}
.sidebar-nav{
  overflow-y:auto;
  overflow-x:hidden;
  padding-right:6px;
  scrollbar-width:thin;
  scrollbar-color:rgba(249,115,22,.75) rgba(255,255,255,.05);
}
.sidebar-nav::-webkit-scrollbar{
  width:6px;
}
.sidebar-nav::-webkit-scrollbar-track{
  background:rgba(255,255,255,.05);
  border-radius:999px;
}
.sidebar-nav::-webkit-scrollbar-thumb{
  background:linear-gradient(180deg,#60a5fa,#2563eb);
  border-radius:999px;
  border:1px solid rgba(17,24,39,.65);
}
.sidebar-nav::-webkit-scrollbar-thumb:hover{
  background:linear-gradient(180deg,#fdba74,#1d4ed8);
}
.sidebar-nav a,
.logout-link{
  margin:4px 0;
  padding:11px 12px;
  border-radius:13px;
}
.sidebar-nav a:hover,
.sidebar-nav a.active{
  box-shadow:inset 3px 0 0 #2563eb,0 10px 24px rgba(0,0,0,.12);
}
.card,
.quick-action,
.topbar-user{
  box-shadow:0 16px 44px rgba(15,23,42,.07);
}
.stat-card{
  min-height:132px;
}
.table-responsive{
  overflow:auto;
  scrollbar-width:thin;
  scrollbar-color:#2563eb #edf1f7;
}
.table-responsive::-webkit-scrollbar{
  width:7px;
  height:7px;
}
.table-responsive::-webkit-scrollbar-track{
  background:#edf1f7;
  border-radius:999px;
}
.table-responsive::-webkit-scrollbar-thumb{
  background:linear-gradient(90deg,#60a5fa,#2563eb);
  border-radius:999px;
}
@media(max-width:991px){
  .sidebar{width:282px;}
  .main{margin-left:0;width:100%;}
}

/* Multi inspection upload UI */
.multi-upload-zone input[type="file"]::file-selector-button,
.upload-zone input[type="file"]::file-selector-button{
    border: 0;
    border-radius: 10px;
    padding: 10px 14px;
    margin-right: 12px;
    background: linear-gradient(135deg, #2563eb, #60a5fa);
    color: #fff;
    font-weight: 700;
    cursor: pointer;
}
.selected-file-list{
    display: grid;
    gap: 10px;
}
.selected-file-card{
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid rgba(249,115,22,.22);
    background: rgba(255,255,255,.82);
    border-radius: 14px;
    box-shadow: 0 10px 28px rgba(15, 23, 42, .06);
}
.selected-file-card .file-badge{
    min-width: 48px;
    text-align: center;
    padding: 5px 8px;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .04em;
}
.selected-file-card .file-name{
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #0f172a;
    font-weight: 700;
}
.selected-file-card .file-size{
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
}


/* Solo Dental CRM blue polish */
.brand-mark{background:linear-gradient(135deg,#60a5fa,#2563eb)}
.workflow-card{background:linear-gradient(135deg,#0f172a,#1d4ed8)}
.badge-soft{background:#eff6ff;color:#1d4ed8;}
.tooth-guide{background:#eff6ff;border:1px solid #bfdbfe;border-radius:20px;padding:18px;}
.case-field{background:#f8fbff;border:1px solid #dbeafe;border-radius:16px;padding:16px;margin-bottom:12px;}
.case-field strong{display:block;font-size:12px;text-transform:uppercase;letter-spacing:.08em;color:#2563eb;margin-bottom:6px;}


/* v0.3 Solo Dental CRM premium blue polish */
.login-shell{background:radial-gradient(circle at 18% 14%,#dbeafe 0,#eff6ff 26%,transparent 46%),linear-gradient(135deg,#f8fafc,#eef2ff)!important;}
.login-card{border:1px solid rgba(219,234,254,.9);box-shadow:0 30px 90px rgba(30,64,175,.16)!important;}
.login-card .brand-mark{background:linear-gradient(135deg,#60a5fa,#2563eb)!important;}
.sidebar{background:linear-gradient(180deg,#0f172a 0%,#172554 58%,#0b1220 100%)!important;}
.workflow-card{background:linear-gradient(135deg,#172554,#1e3a8a)!important;}
.page-hero{background:linear-gradient(135deg,rgba(255,255,255,.82),rgba(239,246,255,.92));border:1px solid rgba(191,219,254,.65);border-radius:28px;padding:26px;box-shadow:0 22px 60px rgba(30,64,175,.08);}
.stat-card:before{content:"";position:absolute;left:0;top:0;bottom:0;width:4px;background:linear-gradient(180deg,#60a5fa,#2563eb);}
.quick-action:hover{border-color:#bfdbfe;box-shadow:0 18px 44px rgba(37,99,235,.12);}
@media(max-width:640px){.login-card{padding:26px!important}.role-grid{grid-template-columns:1fr!important}}


/* Solo Dental CRM v0.4 refinements */
.tooth-grid{display:grid;grid-template-columns:repeat(8,minmax(54px,1fr));gap:12px;margin-top:10px;padding:16px;border:1px solid #edf1f7;background:linear-gradient(135deg,#f8fbff,#fff);border-radius:22px;}
.tooth-box{border:1px solid #dbeafe;background:#fff;border-radius:16px;min-height:62px;display:flex;flex-direction:column;align-items:center;justify-content:center;color:#172033;box-shadow:0 8px 22px rgba(37,99,235,.08);cursor:pointer;transition:.18s ease;}
.tooth-box strong{font-size:18px;color:#1d4ed8;line-height:1}.tooth-box small{font-size:10px;color:#64748b;margin-top:5px}.tooth-box:hover{transform:translateY(-2px);border-color:#2563eb;box-shadow:0 14px 32px rgba(37,99,235,.14)}
.info-grid.two-col{grid-template-columns:repeat(2,minmax(0,1fr));}
.mini-record{border:1px solid #edf1f7;background:#fbfcff;border-radius:18px;padding:14px;margin-top:12px}.mini-record small{display:block;color:#64748b;margin-top:4px}.prescription-form .medicine-row{background:#fbfcff;border:1px solid #edf1f7;border-radius:18px;padding:12px;margin-left:0;margin-right:0}.medicine-suggestions{position:absolute;z-index:30;left:12px;right:12px;top:100%;background:#fff;border:1px solid #dbeafe;border-radius:14px;box-shadow:0 18px 44px rgba(15,23,42,.12);display:none;overflow:hidden}.medicine-suggestion-item{display:block;width:100%;border:0;background:#fff;padding:10px 12px;text-align:left}.medicine-suggestion-item:hover{background:#eff6ff;color:#1d4ed8}.badge-soft{background:#eff6ff;color:#1d4ed8;}
@media(max-width:900px){.tooth-grid{grid-template-columns:repeat(4,1fr)}.info-grid.two-col{grid-template-columns:1fr}}
@media(max-width:520px){.tooth-grid{grid-template-columns:repeat(2,1fr)}}

/* v0.5.1 Solo Dental CRM bug-fix polish */
.rx-logo,
.prescription-box .rx-logo{
  width:96px !important;
  height:96px !important;
  max-width:96px !important;
  max-height:96px !important;
  object-fit:contain !important;
  background:#fff !important;
  border:1px solid #edf1f7 !important;
  border-radius:20px !important;
  padding:8px !important;
  box-shadow:0 10px 26px rgba(15,23,42,.08) !important;
  flex:0 0 96px !important;
}
.prescription-box .d-flex.gap-3{
  align-items:flex-start;
}
.sidebar-nav a.active{
  background:linear-gradient(135deg,rgba(37,99,235,.28),rgba(96,165,250,.22)) !important;
  color:#fff !important;
  box-shadow:inset 4px 0 0 #60a5fa,0 14px 28px rgba(0,0,0,.16) !important;
  transform:translateX(3px);
}
.sidebar-nav a.active span{
  background:linear-gradient(135deg,#60a5fa,#2563eb) !important;
  color:#fff !important;
}
.brand-mark img,
.login-brand-mark img{
  width:100% !important;
  height:100% !important;
  object-fit:contain !important;
  display:block !important;
}
.settings-logo-preview{
  display:flex;
  align-items:center;
  gap:12px;
  margin-top:10px;
  padding:10px;
  border:1px solid #edf1f7;
  border-radius:16px;
  background:#fbfcff;
}
.settings-logo-preview img{
  width:56px;
  height:56px;
  object-fit:contain;
  border-radius:14px;
  background:#fff;
  border:1px solid #edf1f7;
}
@media(max-width:760px){
  .prescription-box .d-flex.justify-content-between{flex-direction:column;gap:16px;}
  .rx-logo,.prescription-box .rx-logo{width:72px!important;height:72px!important;max-width:72px!important;max-height:72px!important;flex-basis:72px!important;}
}

/* Prescription detail meta cards */
.rx-patient-grid{
    display:grid;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:12px;
    padding-bottom:18px;
    border-bottom:1px solid var(--border);
}
.rx-patient-grid > div{
    background:#f8fbff;
    border:1px solid #dbeafe;
    border-radius:16px;
    padding:13px 15px;
    min-height:72px;
}
.rx-patient-grid span{
    display:block;
    margin-bottom:5px;
    font-size:11px;
    font-weight:800;
    letter-spacing:.08em;
    text-transform:uppercase;
    color:#2563eb;
}
.rx-patient-grid strong{
    display:block;
    color:#0f172a;
    font-size:14px;
    line-height:1.45;
}
@media(max-width:992px){.rx-patient-grid{grid-template-columns:repeat(2,minmax(0,1fr));}}
@media(max-width:576px){.rx-patient-grid{grid-template-columns:1fr;}}

/* v0.7 Solo Dental CRM finishing polish */
.dental-patient-card{
  background:linear-gradient(135deg,#172554,#1e3a8a) !important;
  color:#fff !important;
  border:1px solid rgba(96,165,250,.35) !important;
  box-shadow:0 24px 60px rgba(15,23,42,.16) !important;
}
.dental-patient-card h5,.dental-patient-card strong{color:#fff!important;}
.dental-patient-card .text-muted{color:#dbeafe!important;}
.table td:last-child,.table th:last-child{min-width:150px;}
.badge-status-active{background:#dcfce7;color:#166534;border-radius:999px;padding:6px 10px;font-weight:800;font-size:12px;}
.badge-status-inactive{background:#fee2e2;color:#991b1b;border-radius:999px;padding:6px 10px;font-weight:800;font-size:12px;}
.solo-performance-card{background:linear-gradient(135deg,#0f172a,#1d4ed8);color:#fff;border-radius:24px;padding:24px;box-shadow:0 24px 70px rgba(30,64,175,.20);}
.solo-performance-card .metric{background:rgba(255,255,255,.10);border:1px solid rgba(255,255,255,.16);border-radius:18px;padding:16px;}
.solo-performance-card small{color:#bfdbfe;text-transform:uppercase;letter-spacing:.08em;font-weight:800;}
.solo-performance-card strong{display:block;color:#fff;font-size:26px;margin-top:5px;}

.working-days{display:flex;flex-wrap:wrap;gap:10px;margin-top:8px}.day-pill{border:1px solid #d7e3f7;border-radius:999px;padding:10px 14px;background:#fff;cursor:pointer;font-weight:700;color:#12213b}.day-pill input{margin-right:7px}.day-pill:has(input:checked){background:linear-gradient(135deg,#2f6ff4,#5aa7ff);color:#fff;border-color:#2f6ff4;box-shadow:0 10px 24px rgba(47,111,244,.18)}

/* v1.0 Dentist license and signature polish */
.rx-patient-grid small,.rx-signature-block small,.issued-by-box small{display:block;color:#64748b;font-size:12px;line-height:1.45;margin-top:4px;max-width:420px;}
.dentist-signature{max-width:170px;max-height:72px;object-fit:contain;background:#fff;border:1px solid #e5eefb;border-radius:12px;padding:6px;margin-bottom:8px;}
.issued-by-box{background:#f8fbff;border:1px solid #dbeafe;border-radius:18px;padding:16px;min-width:280px;color:#0f172a;}
.invoice-signature-wrap{gap:24px;}
@media(max-width:768px){.invoice-signature-wrap{flex-direction:column;align-items:stretch!important}.invoice-signature-wrap .text-end{text-align:left!important}.issued-by-box{min-width:0;width:100%;}}

/* v1.0 dental chart integration */
.dental-chart-history-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:16px}
.dental-chart-history-card{border:1px solid #dbeafe;background:linear-gradient(135deg,#ffffff,#f7fbff);border-radius:22px;padding:18px;box-shadow:0 14px 35px rgba(15,23,42,.06)}
.dental-chart-history-card small,.dental-chart-history-card label{display:block;text-transform:uppercase;letter-spacing:.08em;font-size:11px;color:#2563eb;font-weight:800;margin-bottom:2px}
.dental-chart-history-card h4{font-weight:900;margin:0;color:#0b1736}
.dental-chart-history-card strong{color:#0b1736;font-weight:800}

/* v1.0 mobile sidebar polish: keep hamburger away from logo */
@media(max-width:991px){
  .mws-mobile-menu-btn{
    top:18px;
    left:18px;
    z-index:1205;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    flex:0 0 46px;
  }
  .sidebar{
    padding-top:18px;
    overflow:hidden;
  }
  .sidebar .brand{
    min-height:76px;
    padding:10px 10px 18px 66px;
    gap:10px;
    position:relative;
  }
  .sidebar .brand-mark{
    width:42px;
    height:42px;
    border-radius:14px;
    flex:0 0 42px;
  }
  .sidebar .brand strong{
    font-size:14px;
    white-space:nowrap;
  }
  .sidebar .brand span{
    font-size:11px;
  }
  .sidebar-nav{
    max-height:calc(100vh - 155px);
    overflow-y:auto;
    overscroll-behavior:contain;
  }
  .mws-menu-open{
    overflow:hidden;
  }
}

@media(max-width:380px){
  .sidebar{width:82vw;max-width:286px;}
  .sidebar .brand{padding-left:62px;}
  .mws-mobile-menu-btn{width:42px;height:42px;border-radius:13px;}
}
