/* ==========================================================================
   PrintCount — UI Kit (Shadcn-inspired, light theme)
   Stack: CSS puro. Preserva todos os seletores usados pelos scripts
   (assets/admin.js, assets/client.js, assets/common.js, assets/messenger.js).
   Não há build de frontend.
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* --------------------------------------------------------------------------
   Design tokens
   -------------------------------------------------------------------------- */
:root{
  /* Font */
  --font: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  /* Surfaces */
  --page:        #f8fafc;   /* slate-50  (fundo da aplicação) */
  --background:  #ffffff;   /* cards, sidebar, header */
  --foreground:  #0f172a;   /* slate-900 (texto principal) */

  /* Muted / secondary text */
  --muted:       #64748b;   /* slate-500 */
  --muted-soft:  #94a3b8;   /* slate-400 */

  /* Brand / primary */
  --primary:        #2563eb;  /* blue-600 */
  --primary-hover:  #1d4ed7;  /* blue-700 */
  --primary-soft:   #eff6ff;  /* blue-50  (fundos de destaque) */
  --primary-foreground: #ffffff;

  /* States */
  --success:       #16a34a;   /* green-600 */
  --success-soft:  #ecfdf5;   /* green-50  */
  --warning:       #d97706;   /* amber-600 */
  --warning-soft:  #fffbeb;   /* amber-50  */
  --danger:        #dc2626;   /* red-600 */
  --danger-soft:   #fef2f2;   /* red-50   */

  /* Borders */
  --border:       #e2e8f0;    /* slate-200 */
  --border-soft:  #eef2f7;    /* slate-100/200 */
  --input:        #e2e8f0;
  --ring:         #93c5fd;    /* blue-300 (focus ring) */

  /* Accent (hover backgrounds) */
  --accent:        #f1f5f9;   /* slate-100 */
  --accent-strong: #e2e8f0;   /* slate-200 */

  /* Radius (Shadcn scale) */
  --radius:    .625rem;          /* 10px */
  --radius-sm: calc(var(--radius) - 6px);  /* 4px */
  --radius-md: calc(var(--radius) - 4px);  /* 6px */
  --radius-lg: var(--radius);              /* 10px */
  --radius-xl: calc(var(--radius) + 6px);  /* 16px */

  /* Shadows */
  --shadow-xs: 0 1px 2px 0 rgba(15,23,42,.05);
  --shadow-sm: 0 1px 3px 0 rgba(15,23,42,.10), 0 1px 2px -1px rgba(15,23,42,.10);
  --shadow-md: 0 4px 10px -2px rgba(15,23,42,.10), 0 2px 4px -2px rgba(15,23,42,.06);
  --shadow-lg: 0 12px 24px -6px rgba(15,23,42,.16), 0 4px 8px -4px rgba(15,23,42,.08);
  --shadow-primary: 0 6px 16px -4px rgba(37,99,235,.35);

  --transition: 160ms cubic-bezier(.4,0,.2,1);
}

/* --------------------------------------------------------------------------
   Reset / base
   -------------------------------------------------------------------------- */
*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
  color: var(--foreground);
  background: var(--page);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
h1,h2,h3{color:var(--foreground); letter-spacing:-.01em}
::selection{background: rgba(37,99,235,.18)}

/* Inline SVG icons (lucide-style). Stroke styling lives here so markup stays terse. */
.icon{
  fill:none; stroke:currentColor;
  stroke-width:2; stroke-linecap:round; stroke-linejoin:round;
  width:18px; height:18px;
}

/* --------------------------------------------------------------------------
   Layout shell
   -------------------------------------------------------------------------- */
.layout{
  display:grid;
  grid-template-columns: 264px 1fr;
  min-height:100vh;
}
/* Used by the mobile drawer (CSS-only, no JS). */
.nav-toggle-input{
  position:absolute; width:1px; height:1px; opacity:0; pointer-events:none;
}
.sidebar-scrim{display:none}

/* --------------------------------------------------------------------------
   Sidebar
   -------------------------------------------------------------------------- */
.sidebar{
  display:flex;
  flex-direction:column;
  gap:6px;
  padding:18px 14px;
  background: var(--background);
  border-right:1px solid var(--border);
}
.brand{
  display:flex; align-items:center; gap:10px;
  font-weight:700; font-size:15px;
  padding:8px 10px 16px;
  color: var(--foreground);
}
.brand-logo{
  width:30px; height:30px; border-radius: var(--radius-sm);
  flex-shrink:0;
}

.nav{display:flex; flex-direction:column; gap:2px}
.nav-item{
  display:flex; width:100%; align-items:center; gap:11px;
  text-align:left; cursor:pointer;
  background:transparent; color: var(--muted);
  border:0;
  padding:9px 11px;
  border-radius: var(--radius-md);
  font-family: var(--font); font-size:14px; font-weight:500;
  transition: background var(--transition), color var(--transition);
}
.nav-icon{
  display:inline-flex; width:20px; height:20px;
  align-items:center; justify-content:center;
  color: var(--muted-soft); flex-shrink:0;
  transition: color var(--transition);
}
.nav-icon .icon{width:19px; height:19px}
.nav-label{white-space:nowrap; overflow:hidden; text-overflow:ellipsis}
.nav-item:hover{background: var(--accent); color: var(--foreground)}
.nav-item:hover .nav-icon{color: var(--muted)}
.nav-item.active{background: var(--primary-soft); color: var(--primary); font-weight:600}
.nav-item.active .nav-icon{color: var(--primary)}
.nav-item:active{transform: scale(.98)}

.nav-bottom{margin-top:auto; display:flex; flex-direction:column; gap:8px; padding-top:12px}
.nav-bottom .btn{justify-content:flex-start}

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */
.content{
  min-width:0;
  display:flex; flex-direction:column;
}
.app-header{
  position:sticky; top:0; z-index:20;
  display:flex; align-items:center; justify-content:space-between; gap:12px;
  padding:14px 26px;
  background: rgba(255,255,255,.82);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom:1px solid var(--border);
}
.app-header h1{
  margin:0; font-size:18px; font-weight:600;
}
.header-start{display:flex; align-items:center; gap:12px; min-width:0}
.header-actions{display:flex; align-items:center; gap:8px}
.nav-toggle-btn{
  display:none;
  align-items:center; justify-content:center;
  width:38px; height:38px; border-radius: var(--radius-md);
  color: var(--foreground); cursor:pointer;
  border:1px solid var(--border); background: var(--background);
  transition: background var(--transition);
}
.nav-toggle-btn:hover{background: var(--accent)}
.nav-toggle-btn .icon{width:20px; height:20px}

/* --------------------------------------------------------------------------
   Container / views
   -------------------------------------------------------------------------- */
.container{
  width:100%; max-width:1320px; margin:0 auto;
  padding:26px; display:grid; gap:18px;
}
.view[hidden]{display:none}
.view-clientes, .view-subclientes{display:grid; gap:18px}
.view-clientes > *, .view-subclientes > *{opacity:0; transform: translateY(8px)}
.view-clientes.is-animated > *, .view-subclientes.is-animated > *{
  opacity:1; transform: translateY(0);
  transition: opacity .3s ease, transform .3s ease;
}
.view-clientes.is-animated > *:nth-child(2),
.view-subclientes.is-animated > *:nth-child(2){transition-delay:.05s}
.view-clientes.is-animated > *:nth-child(3),
.view-subclientes.is-animated > *:nth-child(3){transition-delay:.1s}

/* --------------------------------------------------------------------------
   Summary grid (totals row)
   -------------------------------------------------------------------------- */
.clients-summary-grid{
  display:grid; gap:14px;
  grid-template-columns: repeat(3, minmax(0,1fr));
}
.summary-card{
  background: var(--background);
  border:1px solid var(--border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xs);
  padding:20px 22px;
  transition: box-shadow var(--transition), border-color var(--transition), transform var(--transition);
}
.summary-card:hover{box-shadow: var(--shadow-sm); transform: translateY(-1px); border-color: var(--accent-strong)}
.summary-label{
  color: var(--muted); font-size:12.5px; font-weight:500;
  letter-spacing:.02em;
}
.summary-value{
  margin-top:8px;
  font-size:30px; font-weight:700; line-height:1;
  font-variant-numeric: tabular-nums;
  color: var(--foreground);
}

/* --------------------------------------------------------------------------
   Stats grid (dashboard KPIs)
   -------------------------------------------------------------------------- */
.stats-grid{
  display:grid; gap:14px;
  grid-template-columns: repeat(auto-fit, minmax(220px,1fr));
}
.stat-card{
  display:flex; align-items:center; gap:14px;
  background: var(--background);
  border:1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
  padding:18px 20px;
  transition: box-shadow var(--transition), border-color var(--transition), transform var(--transition);
}
.stat-card:hover{box-shadow: var(--shadow-sm); transform: translateY(-1px); border-color: var(--accent-strong)}
.stat-icon{
  display:inline-flex; align-items:center; justify-content:center;
  width:44px; height:44px; flex-shrink:0;
  border-radius: var(--radius-md);
  background: var(--primary-soft); color: var(--primary);
}
.stat-icon .icon{width:22px; height:22px}
.stat-content{flex:1; min-width:0}
.stat-label{font-size:13px; color:var(--muted); margin-bottom:2px; font-weight:500}
.stat-value{font-size:26px; font-weight:700; color:var(--foreground); line-height:1.1; font-variant-numeric: tabular-nums}

/* --------------------------------------------------------------------------
   Cards
   -------------------------------------------------------------------------- */
.card{
  background: var(--background);
  border:1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs);
  padding:20px;
}
.card h2{margin:0 0 14px; font-size:15px; font-weight:600}
.card h3{margin:18px 0 10px; font-size:14px; font-weight:600}
.card-header{
  display:flex; align-items:center; justify-content:space-between;
  gap:12px; margin-bottom:14px; flex-wrap:wrap;
}
.card-form{
  background: var(--page);
  border-style: dashed;
}
.card-clients{
  box-shadow: var(--shadow-sm);
}

/* --------------------------------------------------------------------------
   Toolbar / search
   -------------------------------------------------------------------------- */
.toolbar{display:flex; align-items:center; gap:8px; flex-wrap:wrap}
.toolbar .btn.primary{white-space:nowrap}
.toolbar input[type="search"]{
  width:300px; max-width:100%;
}
.report-toolbar{flex-wrap:wrap}
.report-toolbar label{display:grid; gap:4px}
.report-toolbar label > span{font-size:12px; color:var(--muted)}
.input-search{position:relative; display:inline-flex; align-items:center}
.input-search .icon{
  position:absolute; left:10px; width:16px; height:16px;
  color: var(--muted-soft); pointer-events:none;
}
.input-search input[type="search"]{padding-left:32px; width:300px; max-width:100%}

/* --------------------------------------------------------------------------
   Forms
   -------------------------------------------------------------------------- */
.form-grid{display:grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap:14px}
.form-field{display:flex; flex-direction:column; gap:6px}
.form-field:has(> input[type="hidden"]){display:none}
label{font-size:12.5px; color:var(--muted); font-weight:500}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="number"],
input[type="date"],
select, textarea{
  width:100%;
  appearance:none;
  background: var(--background);
  color: var(--foreground);
  border:1px solid var(--input);
  border-radius: var(--radius-md);
  padding:9px 12px;
  font-family: var(--font); font-size:14px;
  outline:none;
  transition: border-color var(--transition), box-shadow var(--transition);
}
input::placeholder, textarea::placeholder{color: var(--muted-soft)}
input:focus, textarea:focus, select:focus{
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37,99,235,.15);
}
/* Native select affordance */
select{
  cursor:pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat:no-repeat;
  background-position: right 10px center;
  background-size:16px;
  padding-right:34px;
}
select.select-field{min-width:240px}
input[type="search"]::-webkit-search-cancel-button{appearance:none}
.form-actions{
  grid-column: 1 / -1;
  display:flex; gap:8px; justify-content:flex-end; margin-top:6px;
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */
.btn{
  appearance:none; cursor:pointer;
  display:inline-flex; align-items:center; justify-content:center; gap:7px;
  border:1px solid var(--border);
  background: var(--background); color: var(--foreground);
  padding:9px 15px;
  border-radius: var(--radius-md);
  font-family: var(--font); font-size:13.5px; font-weight:500;
  line-height:1;
  white-space:nowrap;
  transition: background var(--transition), border-color var(--transition), color var(--transition), box-shadow var(--transition), transform var(--transition);
}
.btn:hover{background: var(--accent)}
.btn:active{transform: translateY(1px)}
.btn:focus-visible{outline:none; box-shadow:0 0 0 3px rgba(37,99,235,.18)}
.btn:disabled{opacity:.55; cursor:not-allowed; pointer-events:none}
.btn .icon{width:16px; height:16px}

.btn.primary{
  background: var(--primary); border-color: var(--primary);
  color: var(--primary-foreground); font-weight:600;
}
.btn.primary:hover{background: var(--primary-hover); border-color: var(--primary-hover)}
.btn.primary:focus-visible{box-shadow:0 0 0 3px rgba(37,99,235,.25)}

.btn.ghost{background:transparent; border-color:transparent; color:var(--muted)}
.btn.ghost:hover{background: var(--accent); color:var(--foreground)}

.btn.outline{background:transparent; border-color:var(--border)}
.btn.outline:hover{background: var(--accent)}

.btn.danger{background:var(--danger); border-color:var(--danger); color:#fff; font-weight:600}
.btn.danger:hover{filter:brightness(1.05)}

.btn.success{background:var(--success); border-color:var(--success); color:#fff; font-weight:600}
.btn.success:hover{filter:brightness(1.05)}

.btn.warning{background:var(--warning); border-color:var(--warning); color:#fff; font-weight:600}
.btn.warning:hover{filter:brightness(1.05)}

.btn.action-secondary{background:var(--background)}
.btn.action-primary{box-shadow: var(--shadow-xs)}

.icon-btn{
  display:inline-flex; align-items:center; justify-content:center;
  width:32px; height:32px;
  background:transparent; border:0; cursor:pointer;
  color:var(--muted); border-radius: var(--radius-sm);
  transition: background var(--transition), color var(--transition);
}
.icon-btn:hover{background:var(--accent); color:var(--foreground)}
.icon-btn .icon{width:18px; height:18px}

/* --------------------------------------------------------------------------
   Tables
   -------------------------------------------------------------------------- */
.table-responsive{
  overflow:auto;
  border:1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--background);
}
table.table{width:100%; border-collapse:collapse}
table.table thead th{
  position:sticky; top:0; z-index:1;
  background: var(--page);
  text-align:left; font-weight:600; font-size:11.5px;
  color: var(--muted);
  padding:11px 14px;
  border-bottom:1px solid var(--border);
  text-transform:uppercase; letter-spacing:.04em;
  white-space:nowrap;
}
table.table tbody td{
  padding:12px 14px;
  border-bottom:1px solid var(--border-soft);
  font-size:13.5px; vertical-align:middle;
  font-variant-numeric: tabular-nums;
}
table.table tbody tr:last-child td{border-bottom:0}
table.table tbody tr{transition: background var(--transition)}
table.table tbody tr:hover{background: var(--primary-soft)}
table.table .actions{display:flex; gap:6px; flex-wrap:wrap}
table.table .actions .btn{padding:6px 11px; font-size:12.5px}
table.table.compact thead th,
table.table.compact tbody td{padding:8px 12px; font-size:13px}
.cell-id{font-weight:600; color:var(--primary); font-variant-numeric: tabular-nums}
.cell-ellipsis{max-width:240px}
.cell-ellipsis-content{display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap}
.table-empty-row:hover{background:transparent !important}
.table-empty-cell{
  text-align:center; padding:34px 12px !important;
  color:var(--muted); font-weight:500; font-size:14px;
}

/* --------------------------------------------------------------------------
   Badges / chips
   -------------------------------------------------------------------------- */
.count-badge{
  display:inline-flex; min-width:30px;
  justify-content:center; align-items:center;
  padding:3px 9px;
  border-radius:999px;
  font-weight:600; font-size:12px;
  color: var(--primary);
  background: var(--primary-soft);
  font-variant-numeric: tabular-nums;
}
.status-chip{
  display:inline-flex; align-items:center; gap:6px;
  padding:3px 10px;
  border-radius:999px;
  font-size:12px; font-weight:600;
  border:1px solid transparent;
}
.status-chip::before{
  content:""; width:6px; height:6px; border-radius:50%;
  background: currentColor; opacity:.85;
}
.status-chip.active{background: var(--success-soft); color: var(--success)}
.status-chip.inactive{background: var(--danger-soft); color: var(--danger)}

/* --------------------------------------------------------------------------
   Modals
   -------------------------------------------------------------------------- */
.modal{position:fixed; inset:0; display:none; z-index:100}
.modal[aria-hidden="false"]{display:block}
.modal-backdrop{
  position:absolute; inset:0;
  background: rgba(15,23,42,.45);
  backdrop-filter: blur(3px);
  animation: fade-in .15s ease;
}
.modal-content{
  position:relative;
  background: var(--background);
  border:1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  width:min(640px, calc(100% - 24px));
  margin: 8vh auto 0;
  max-height: 84vh; overflow:hidden;
  display:flex; flex-direction:column;
  animation: pop-in .16s cubic-bezier(.4,0,.2,1);
}
.modal-large .modal-content{width:min(1080px, calc(100% - 24px))}
.modal-header{
  display:flex; align-items:center; justify-content:space-between; gap:10px;
  padding:16px 20px;
  border-bottom:1px solid var(--border);
}
.modal-header h3{margin:0; font-size:15px; font-weight:600}
.modal-body{padding:18px 20px; overflow:auto}
.modal-footer{
  display:flex; justify-content:flex-end; gap:8px;
  padding:14px 20px;
  border-top:1px solid var(--border);
  background: var(--page);
}
#confirm-message{margin:0; color:var(--foreground); line-height:1.6; font-size:14px}
@keyframes fade-in{from{opacity:0}to{opacity:1}}
@keyframes pop-in{from{opacity:0; transform: translateY(6px) scale(.99)}to{opacity:1; transform:none}}

.list{list-style:none; padding:0; margin:0; display:grid; gap:8px}
.list li{padding:10px 12px; border:1px solid var(--border); border-radius: var(--radius-md); background:var(--page)}

/* --------------------------------------------------------------------------
   Toasts
   -------------------------------------------------------------------------- */
.toast-container{
  position:fixed; right:20px; bottom:20px;
  display:flex; flex-direction:column; gap:10px; z-index:120;
}
.toast{
  position:relative;
  display:flex; align-items:flex-start; gap:10px;
  min-width:260px; max-width:380px;
  padding:12px 38px 12px 14px;
  border:1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--background);
  color: var(--foreground);
  box-shadow: var(--shadow-lg);
  font-size:13.5px; font-weight:500;
  animation: toast-in .18s cubic-bezier(.4,0,.2,1);
}
.toast.success{border-color:#bbf7d0}
.toast.success .toast-mark{color: var(--success)}
.toast.error{border-color:#fecaca}
.toast.error .toast-mark{color: var(--danger)}
.toast.warning{border-color:#fde68a}
.toast.warning .toast-mark{color: var(--warning)}
.toast.info{border-color:#bfdbfe}
.toast.info .toast-mark{color: var(--primary)}
.toast.hide{opacity:0; transform: translateY(6px); transition: opacity .15s ease, transform .15s ease}
.toast-close{
  position:absolute; top:8px; right:8px;
  width:22px; height:22px;
  display:inline-flex; align-items:center; justify-content:center;
  background:transparent; border:0; cursor:pointer;
  color: var(--muted); border-radius: var(--radius-sm);
}
.toast-close:hover{background: var(--accent); color: var(--foreground)}
.toast-close{font-size:20px; font-weight:300; line-height:1; color:var(--muted)}
@keyframes toast-in{from{opacity:0; transform: translateY(10px)}to{opacity:1; transform:none}}

/* --------------------------------------------------------------------------
   Language selector
   -------------------------------------------------------------------------- */
.language-selector,
.login-language-selector{
  appearance:none;
  background-color: var(--background);
  color: var(--foreground);
  border:1px solid var(--border);
  border-radius: var(--radius-md);
  padding:7px 30px 7px 11px;
  font-family: var(--font); font-size:13px; font-weight:500;
  cursor:pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat:no-repeat;
  background-position: right 8px center;
  background-size:15px;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.language-selector:hover, .login-language-selector:hover{border-color: var(--accent-strong)}
.language-selector:focus, .login-language-selector:focus{
  border-color: var(--primary);
  box-shadow:0 0 0 3px rgba(37,99,235,.15); outline:none;
}
.login-language-selector{position:absolute; top:16px; right:16px}

/* --------------------------------------------------------------------------
   Migrations panel
   -------------------------------------------------------------------------- */
.migrations-info{
  background: var(--page);
  border:1px solid var(--border);
  border-radius: var(--radius-md);
  padding:16px 18px;
  margin-bottom:16px;
}
.migrations-info-grid{display:grid; grid-template-columns: repeat(auto-fit, minmax(200px,1fr)); gap:16px}
.migrations-info strong{
  display:block; font-size:12px; color:var(--muted);
  font-weight:500; text-transform:uppercase; letter-spacing:.04em;
}
.migrations-version{font-size:22px; color:var(--primary); font-weight:700; font-variant-numeric: tabular-nums; margin-top:4px}
.migrations-status{font-size:15px; font-weight:600; margin-top:4px}

/* --------------------------------------------------------------------------
   Login page
   -------------------------------------------------------------------------- */
.login-header{
  display:flex; align-items:center; justify-content:center;
  padding:46px 24px 6px;
}
.login-view{
  min-height: calc(100vh - 150px);
  display:flex; align-items:center; justify-content:center;
  padding:24px;
}
.login-card{width:min(440px, 100%); padding:30px}
.login-card h2{font-size:19px; font-weight:700; margin:0 0 4px}
.login-card .login-subtitle{color:var(--muted); font-size:13.5px; margin:0 0 22px}
.login-brand{display:flex; align-items:center; gap:10px}
.login-brand span{font-size:22px; font-weight:700; letter-spacing:-.02em}
.login-brand-logo{width:36px; height:36px; border-radius: var(--radius-sm)}
.muted{color:var(--muted); font-size:12px; margin:4px 0 0}

/* --------------------------------------------------------------------------
   Responsive: sidebar becomes a drawer (CSS-only)
   -------------------------------------------------------------------------- */
@media (max-width: 1024px){
  .nav-toggle-btn{display:inline-flex}
  .layout{grid-template-columns:1fr}
  .sidebar{
    position:fixed; top:0; left:0; bottom:0;
    width:280px; max-width:86vw; z-index:60;
    transform: translateX(-100%);
    transition: transform .25s cubic-bezier(.4,0,.2,1);
    box-shadow: var(--shadow-lg);
  }
  .sidebar-scrim{
    display:block;
    position:fixed; inset:0; z-index:55;
    background: rgba(15,23,42,.45);
    opacity:0; visibility:hidden;
    transition: opacity .25s ease, visibility .25s ease;
  }
  .nav-toggle-input:checked ~ .layout .sidebar{transform:none}
  .nav-toggle-input:checked ~ .layout .sidebar-scrim{opacity:1; visibility:visible}
  .app-header{padding:12px 16px}
}

@media (max-width: 720px){
  .container{padding:18px 14px; gap:14px}
  .form-grid{grid-template-columns:1fr}
  .clients-summary-grid{grid-template-columns:1fr}
  .toolbar{width:100%}
  .toolbar input[type="search"],
  .input-search input[type="search"]{width:100%}
  .modal-content{margin-top:4vh; max-height:92vh}
  .stat-value{font-size:24px}
  .summary-value{font-size:26px}
}

/* --------------------------------------------------------------------------
   Reduced motion
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce){
  *, *::before, *::after{
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}
