:root{--bg:#f5f7fb;--panel:#fff;--panel-soft:#f9fafc;--text:#111827;--muted:#6b7280;--line:#e5e7eb;--primary:#111827;--primary-soft:#1f2937;--accent:#c59d5f;--accent-soft:#fbf5ea;--danger:#dc2626;--success:#16a34a;--warning:#d97706;--radius:22px;--shadow:0 22px 55px rgba(15,23,42,.07);--sidebar:282px}*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;background:linear-gradient(180deg,#f7f8fc 0%,var(--bg) 100%);color:var(--text);font-family:Inter,ui-sans-serif,system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif}a{color:inherit;text-decoration:none}button,input,select,textarea{font:inherit}img{max-width:100%}.admin-shell{display:flex;min-height:100vh}.sidebar{width:var(--sidebar);background:linear-gradient(180deg,#0f172a 0%,#111827 100%);color:#e5e7eb;padding:22px;position:sticky;top:0;height:100vh;z-index:40;box-shadow:12px 0 40px rgba(15,23,42,.12)}.sidebar-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:26px}.brand,.portal-brand,.auth-brand{display:grid;gap:2px;font-weight:950;letter-spacing:-.03em}.brand span,.portal-brand span,.auth-brand span{font-size:26px;color:#fff}.brand small,.portal-brand small,.auth-brand small{color:#cbd5e1;font-size:12px;font-weight:800;letter-spacing:.08em;text-transform:uppercase}.sidebar-close{display:none;border:0;background:rgba(255,255,255,.08);color:#fff;width:40px;height:40px;border-radius:14px;font-size:28px;line-height:1;cursor:pointer}.admin-nav{display:grid;gap:14px}.nav-group{border-top:1px solid rgba(255,255,255,.08);padding-top:12px}.nav-group:first-child{border-top:0;padding-top:0}.nav-toggle{width:100%;border:0;background:transparent;color:#94a3b8;font-size:11px;font-weight:950;text-transform:uppercase;letter-spacing:.11em;text-align:left;padding:4px 4px 9px;cursor:pointer}.nav-submenu{display:grid;gap:6px}.nav-submenu a{display:flex;align-items:center;gap:10px;padding:12px 14px;border-radius:15px;color:#cbd5e1;font-size:14px;font-weight:750}.nav-submenu a:hover,.nav-submenu a.active{background:rgba(255,255,255,.09);color:#fff}.nav-submenu a.active{box-shadow:inset 0 0 0 1px rgba(197,157,95,.35)}.nav-dot{width:7px;height:7px;border-radius:50%;background:#475569}.active .nav-dot{background:var(--accent)}.admin-main{flex:1;min-width:0;padding:24px clamp(16px,2.6vw,34px) 44px}.topbar{min-height:72px;background:rgba(255,255,255,.88);border:1px solid var(--line);border-radius:26px;padding:14px 18px;margin-bottom:24px;display:flex;align-items:center;justify-content:space-between;gap:16px;box-shadow:0 14px 35px rgba(15,23,42,.045);backdrop-filter:blur(14px);position:sticky;top:16px;z-index:20}.topbar-left,.topbar-user{display:flex;align-items:center;gap:12px}.topbar-left strong{display:block;font-size:16px}.topbar-left small{display:block;color:var(--muted);font-size:12px}.user-pill{display:inline-flex;align-items:center;min-height:36px;padding:0 12px;border:1px solid var(--line);border-radius:999px;background:#fff;color:var(--muted);font-weight:800}.menu-toggle{display:none;width:44px;height:44px;border:1px solid var(--line);border-radius:15px;background:#fff;align-items:center;justify-content:center;gap:4px;flex-direction:column;cursor:pointer}.menu-toggle span{width:18px;height:2px;border-radius:9px;background:var(--primary)}.mobile-overlay{display:none}.page-head{margin:0 0 24px}.page-head.row{display:flex;justify-content:space-between;align-items:flex-end;gap:18px}.page-head h1{font-size:clamp(28px,4vw,42px);line-height:1.05;margin:4px 0 8px;letter-spacing:-.045em}.page-head p,.muted{color:var(--muted);margin:.35rem 0;line-height:1.55}.eyebrow{display:inline-flex;color:#8a5f1b;background:var(--accent-soft);border:1px solid #f1dfbd;border-radius:999px;padding:6px 10px;font-size:12px;font-weight:950;text-transform:uppercase;letter-spacing:.08em}.grid{display:grid;gap:20px}.cards{grid-template-columns:repeat(auto-fit,minmax(190px,1fr));margin-bottom:20px}.two{grid-template-columns:repeat(2,minmax(0,1fr))}.three{grid-template-columns:repeat(3,minmax(0,1fr))}.span2{grid-column:1/-1}.span3{grid-column:1/-1}.card{background:var(--panel);border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow);padding:clamp(18px,2.2vw,28px);margin-bottom:20px}.card h2,.section-title h2{margin:0 0 7px;font-size:clamp(19px,2.2vw,24px);letter-spacing:-.03em}.section-title{padding-bottom:12px;margin-bottom:18px;border-bottom:1px solid var(--line)}.kpi{position:relative;overflow:hidden}.kpi:after{content:"";position:absolute;right:-28px;top:-38px;width:95px;height:95px;border-radius:50%;background:linear-gradient(135deg,rgba(197,157,95,.18),rgba(197,157,95,0))}.kpi span{display:block;color:var(--muted);font-size:13px;font-weight:800;text-transform:uppercase;letter-spacing:.05em}.kpi strong{display:block;margin-top:8px;font-size:clamp(25px,3.5vw,34px);letter-spacing:-.045em}.table-wrap{width:100%;overflow:auto;border:1px solid var(--line);border-radius:18px;background:#fff}table{width:100%;border-collapse:separate;border-spacing:0}th,td{text-align:left;padding:15px 16px;border-bottom:1px solid var(--line);vertical-align:middle}tr:last-child td{border-bottom:0}th{font-size:11px;text-transform:uppercase;color:var(--muted);letter-spacing:.075em;background:#fbfcff;font-weight:950;white-space:nowrap}tbody tr{transition:background .16s}tbody tr:hover{background:#fbfcff}.data-table td{min-height:52px}.empty-state{padding:26px!important;text-align:center!important;color:var(--muted);background:#fbfcff}.ua-cell{max-width:420px;word-break:break-word}.btn{display:inline-flex;align-items:center;justify-content:center;border:1px solid var(--line);background:#fff;color:#111;padding:11px 15px;border-radius:14px;cursor:pointer;font-weight:850;gap:8px;min-height:42px;transition:transform .15s,box-shadow .15s,background .15s}.btn:hover{transform:translateY(-1px);box-shadow:0 10px 24px rgba(15,23,42,.08)}.btn.primary{background:var(--primary);color:#fff;border-color:var(--primary)}.btn.danger{background:#fff1f1;color:var(--danger);border-color:#ffd5d2}.btn.success{background:#ecfdf3;color:var(--success);border-color:#abefc6}.btn.ghost{background:#f8fafc}.btn.small{font-size:12px;padding:8px 11px;border-radius:11px;min-height:34px}.btn.full{width:100%;margin-top:16px}.actions{display:flex;gap:8px;flex-wrap:wrap;align-items:center}.actions.end{justify-content:flex-end}.actions form{display:inline-flex;margin:0}.bulk-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:12px}.badge{display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;padding:6px 10px;border-radius:999px;font-weight:950;font-size:12px;background:#eef2ff;color:#3538cd}.badge.paid,.badge.active{background:#ecfdf3;color:#067647}.badge.pending{background:#fff8e6;color:#b54708}.badge.inactive,.badge.cancelled{background:#fff1f1;color:#b42318}.alert{padding:15px 17px;border-radius:18px;margin-bottom:18px;border:1px solid transparent;font-weight:750}.alert.success{background:#ecfdf3;color:#067647;border-color:#abefc6}.alert.error{background:#fef3f2;color:#b42318;border-color:#fecdca}.alert.warning{background:#fffaeb;color:#93370d;border-color:#fedf89}.form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}label{display:grid;gap:8px;font-weight:850;color:#2f3542;font-size:14px}input,select,textarea{width:100%;border:1px solid var(--line);border-radius:15px;padding:13px 14px;background:#fff;color:var(--text);outline:none;transition:border .15s,box-shadow .15s}input:focus,select:focus,textarea:focus{border-color:#b89863;box-shadow:0 0 0 4px rgba(197,157,95,.14)}textarea{min-height:120px;resize:vertical}.field-hint{display:block;color:var(--muted);font-size:12px;font-weight:650;line-height:1.4}.hint-box{background:#fbfcff;border:1px dashed #d8dee9;border-radius:17px;padding:14px;color:var(--muted);font-size:14px}.check{display:flex;align-items:center;gap:10px}.check input,.checks input,.select-col input{width:auto}.checks{display:grid;gap:12px}.security-checks{grid-template-columns:repeat(2,minmax(0,1fr))}.security-checks label{display:flex;align-items:flex-start;gap:11px;background:#fbfcff;border:1px solid var(--line);border-radius:17px;padding:14px}.security-checks small{display:block;color:var(--muted);font-weight:650;margin-top:2px}.extra-row{display:grid;grid-template-columns:minmax(0,1fr) 170px;gap:10px;margin-bottom:10px}.inline-upload{display:grid;grid-template-columns:minmax(160px,1fr) auto;gap:8px;align-items:center;margin-top:8px}.inline-upload input{padding:8px}.inline-form{display:grid;grid-template-columns:1fr auto;gap:12px;align-items:end}.sticky-actions{position:sticky;bottom:18px;z-index:5;background:rgba(255,255,255,.88);backdrop-filter:blur(12px);padding:12px;border:1px solid var(--line);border-radius:20px;box-shadow:0 12px 36px rgba(15,23,42,.08)}code{background:#f3f4f6;border:1px solid var(--line);border-radius:9px;padding:3px 6px;font-size:12px;color:#374151}.auth-body{min-height:100vh;display:grid;place-items:center;padding:24px;background:radial-gradient(circle at 10% 10%,#26324d 0,#111827 34%,#0f172a 100%)}.auth-card{width:min(440px,100%);background:#fff;border:1px solid rgba(255,255,255,.2);border-radius:30px;padding:34px;box-shadow:0 35px 90px rgba(0,0,0,.32)}.auth-brand{margin-bottom:20px}.auth-brand span{color:#111827}.auth-brand small{color:#8a5f1b}.auth-card h1{margin:0 0 8px;font-size:30px;letter-spacing:-.04em}.auth-card form{display:grid;gap:13px}.portal-body{background:#f8fafc}.portal-top{margin:18px auto 0;width:min(1180px,calc(100% - 28px));min-height:74px;background:#111827;color:#fff;border-radius:26px;padding:14px clamp(16px,3vw,28px);display:flex;align-items:center;justify-content:space-between;gap:16px;box-shadow:0 22px 55px rgba(15,23,42,.16)}.portal-brand span{font-size:24px}.portal-nav{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.portal-nav a{padding:10px 12px;border-radius:13px;color:#cbd5e1;font-weight:800}.portal-nav a:hover{background:#1f2937;color:#fff}.portal-main{width:min(1180px,calc(100% - 28px));margin:0 auto;padding:30px 0 46px}.security-metrics{grid-template-columns:repeat(4,minmax(0,1fr))}@media(max-width:1120px){.security-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.three{grid-template-columns:1fr}.span3{grid-column:1/-1}}@media(max-width:920px){:root{--sidebar:286px}.sidebar{position:fixed;left:0;top:0;bottom:0;height:100dvh;transform:translateX(-105%);transition:transform .22s ease;box-shadow:20px 0 70px rgba(0,0,0,.28)}body.sidebar-open .sidebar{transform:translateX(0)}.sidebar-close{display:inline-grid;place-items:center}.mobile-overlay{display:block;position:fixed;inset:0;background:rgba(15,23,42,.55);z-index:35;opacity:0;pointer-events:none;transition:opacity .2s}body.sidebar-open .mobile-overlay{opacity:1;pointer-events:auto}.admin-main{padding:14px 14px 34px}.topbar{top:10px;border-radius:22px;align-items:flex-start;flex-direction:column}.topbar-left,.topbar-user{width:100%;justify-content:space-between}.topbar-user{flex-wrap:wrap}.menu-toggle{display:inline-flex}.page-head.row{align-items:flex-start;flex-direction:column}.two,.form-grid{grid-template-columns:1fr}.security-checks{grid-template-columns:1fr}.extra-row,.inline-upload,.inline-form{grid-template-columns:1fr}.card{border-radius:22px;padding:18px}.actions.end{justify-content:flex-start}.portal-top{align-items:flex-start;flex-direction:column;border-radius:22px}.portal-nav{width:100%;justify-content:space-between}.portal-nav a{flex:1;text-align:center}}@media(max-width:700px){.cards,.security-metrics{grid-template-columns:1fr}.table-wrap{border:0;background:transparent;overflow:visible}table.data-table, .data-table thead, .data-table tbody, .data-table th, .data-table td, .data-table tr{display:block}.data-table thead{display:none}.data-table tr{background:#fff;border:1px solid var(--line);border-radius:18px;margin-bottom:12px;box-shadow:0 12px 30px rgba(15,23,42,.04);overflow:hidden}.data-table td{display:flex;justify-content:space-between;gap:14px;padding:13px 14px;border-bottom:1px solid var(--line);text-align:right}.data-table td:last-child{border-bottom:0}.data-table td::before{content:attr(data-label);font-weight:900;color:var(--muted);text-align:left;min-width:110px}.data-table td.select-col{display:block;text-align:left}.data-table td.select-col::before{content:"";display:none}.data-table .actions{justify-content:flex-end}.page-head h1{font-size:30px}.auth-card{padding:26px;border-radius:24px}.topbar-user .btn{flex:1}.user-pill{width:100%;justify-content:center}.inline-upload input{max-width:none}.sticky-actions{position:static}.portal-main{padding-top:22px}}@media(max-width:480px){.admin-main{padding-left:10px;padding-right:10px}.topbar{padding:12px}.card{padding:16px}.portal-top,.portal-main{width:calc(100% - 20px)}.btn{width:auto}.actions .btn,.actions form{width:100%}.actions form .btn{width:100%}}
.nav-group:not(.open) .nav-submenu{display:none}.nav-group.open .nav-toggle{color:#fff}.chip{display:inline-flex;align-items:center;gap:6px;padding:7px 10px;border-radius:999px;background:#f8fafc;border:1px solid var(--line);font-size:12px;font-weight:850;color:#374151}.chip:hover{background:#fff;box-shadow:0 8px 22px rgba(15,23,42,.06)}.portal-main table:not(.data-table){border:1px solid var(--line);border-radius:18px;overflow:hidden}.portal-main table:not(.data-table) th,.portal-main table:not(.data-table) td{padding:15px 16px}@media(max-width:700px){.portal-main table,.portal-main thead,.portal-main tbody,.portal-main th,.portal-main td,.portal-main tr{display:block}.portal-main thead{display:none}.portal-main tr{background:#fff;border:1px solid var(--line);border-radius:18px;margin-bottom:12px;box-shadow:0 12px 30px rgba(15,23,42,.04);overflow:hidden}.portal-main td{display:flex;justify-content:space-between;gap:14px;padding:13px 14px!important;border-bottom:1px solid var(--line);text-align:right}.portal-main td:last-child{border-bottom:0}.portal-main td::before{content:attr(data-label);font-weight:900;color:var(--muted);text-align:left;min-width:110px}.portal-main td[colspan]::before{display:none}.portal-nav{gap:8px}.portal-nav a{font-size:13px;padding:10px 8px}}

/* v1.0.6+ customer portal structure */
.mini{font-size:12px;line-height:1.35}.portal-nav a.active{background:#fff;color:#111827}.portal-welcome{padding-top:4px}.portal-actions-card{display:flex;align-items:center;justify-content:space-between;gap:18px}.portal-actions-card p{max-width:680px}.portal-payments-table th,.payments-admin-table th{white-space:nowrap}.compact-upload{grid-template-columns:minmax(130px,1fr) auto;max-width:280px}.compact-upload input{font-size:12px}.portal-cards .kpi strong{font-size:clamp(21px,2.9vw,30px)}@media(max-width:920px){.portal-actions-card{align-items:flex-start;flex-direction:column}.portal-actions-card .actions{width:100%}.portal-actions-card .btn{flex:1}.portal-nav a.active{box-shadow:inset 0 0 0 1px rgba(255,255,255,.26)}}@media(max-width:700px){.compact-upload{max-width:none}.portal-actions-card .actions,.portal-actions-card .btn{width:100%}.portal-nav{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.portal-nav a{flex:none;width:100%}.portal-payments-table td,.payments-admin-table td{text-align:left;align-items:flex-start;flex-direction:column}.portal-payments-table td::before,.payments-admin-table td::before{min-width:0}.portal-payments-table .chip,.payments-admin-table .chip{width:100%;justify-content:center}.compact-upload{width:100%}}


/* v1.0.7+ table pagination and compact admin actions */
.table-pagination{display:flex;align-items:center;justify-content:space-between;gap:14px;flex-wrap:wrap;margin-top:14px;padding:12px 4px 0}.pagination-info{color:var(--muted);font-size:13px;font-weight:850}.pagination-controls{display:flex;align-items:center;gap:7px;flex-wrap:wrap}.pagination-controls .btn[disabled]{opacity:.45;cursor:not-allowed;transform:none;box-shadow:none}.page-btn.active{background:var(--primary);border-color:var(--primary);color:#fff}.field-hint{margin-top:6px}.payments-admin-table .field-hint{max-width:260px}@media(max-width:700px){.table-pagination{align-items:stretch;flex-direction:column}.pagination-controls{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.pagination-controls .btn{width:100%}.payments-admin-table .field-hint{max-width:none}.clients-admin-table .actions{gap:8px}}
.data-table tr[hidden]{display:none!important}

/* v1.0.9 UI/UX refinements */
.kpi-note{display:block;margin-top:8px;color:var(--muted);font-size:12px;font-weight:750;line-height:1.35}.table-main-text{display:block;max-width:220px;font-weight:900;line-height:1.35}.doc-upload-cell{min-width:230px}.doc-link-row{margin-bottom:9px}.auto-upload{display:grid;grid-template-columns:1fr;gap:6px;max-width:250px}.auto-upload input[type=file]{padding:9px;background:#fbfcff;border-style:dashed;cursor:pointer}.auto-upload.is-uploading{opacity:.72;pointer-events:none}.table-actions{display:grid;gap:8px;min-width:156px}.table-actions .action-row{display:flex;gap:7px;align-items:center;flex-wrap:wrap}.table-actions .btn{min-width:68px}.payments-admin-table td{vertical-align:top}.payments-admin-table .badge{margin-top:1px}.payments-admin-table .field-hint{font-size:11px;margin-top:2px}.payments-admin-table th:last-child,.payments-admin-table td:last-child{position:sticky;right:0;background:#fff;box-shadow:-10px 0 18px rgba(15,23,42,.035)}

.portal-sidebar-layout{background:#f6f7fb}.portal-shell{display:flex;min-height:100vh}.portal-sidebar{width:292px;flex:0 0 292px;padding:24px 22px}.portal-sidebar .portal-brand span{font-size:26px;color:#fff}.portal-client-card{border:1px solid rgba(255,255,255,.10);background:rgba(255,255,255,.06);border-radius:20px;padding:16px;margin-bottom:22px}.portal-client-card span{display:block;color:#94a3b8;font-size:11px;font-weight:950;letter-spacing:.08em;text-transform:uppercase}.portal-client-card strong{display:block;color:#fff;font-size:15px;margin-top:6px;line-height:1.3}.portal-nav-vertical{display:grid;gap:8px}.portal-nav-vertical a{display:flex;align-items:center;gap:12px;color:#cbd5e1;border-radius:16px;padding:13px 14px;font-size:14px;font-weight:850}.portal-nav-vertical a span{width:24px;height:24px;border-radius:9px;display:inline-grid;place-items:center;background:rgba(255,255,255,.07);font-weight:900}.portal-nav-vertical a:hover,.portal-nav-vertical a.active{background:rgba(255,255,255,.10);color:#fff}.portal-nav-vertical a.active{box-shadow:inset 0 0 0 1px rgba(197,157,95,.38)}.portal-sidebar-bottom{margin-top:auto;padding-top:22px}.portal-content{flex:1;min-width:0;padding:24px clamp(16px,2.8vw,38px) 48px}.portal-mobile-top{display:none}.portal-main{width:100%;max-width:1180px;margin:0 auto;padding:0}.portal-summary-grid{grid-template-columns:minmax(260px,1.2fr) minmax(260px,1fr) minmax(190px,.7fr);align-items:stretch;margin-bottom:20px}.portal-plan-card h2{font-size:clamp(24px,3vw,36px);line-height:1.08;letter-spacing:-.04em;margin:12px 0 12px}.yearly-breakdown{display:grid;gap:12px}.year-row{display:flex;align-items:center;justify-content:space-between;gap:18px;border-bottom:1px solid var(--line);padding-bottom:12px}.year-row span{color:var(--muted);font-weight:900}.year-row strong{font-size:20px;letter-spacing:-.03em}.year-row.total{border-bottom:0;background:#111827;color:#fff;margin-top:3px;border-radius:16px;padding:15px}.year-row.total span{color:#d1d5db}.year-row.total strong{font-size:26px}.portal-hour-card strong{font-size:clamp(27px,3.3vw,38px)}

@media(max-width:1180px){.portal-summary-grid{grid-template-columns:1fr 1fr}.portal-hour-card{grid-column:1/-1}.payments-admin-table th:last-child,.payments-admin-table td:last-child{position:static;box-shadow:none}}
@media(max-width:920px){.portal-shell{display:block}.portal-sidebar{position:fixed;left:0;top:0;bottom:0;height:100dvh;transform:translateX(-105%);transition:transform .22s ease;z-index:40;box-shadow:20px 0 70px rgba(0,0,0,.28)}body.sidebar-open .portal-sidebar{transform:translateX(0)}.portal-content{padding:14px 14px 38px}.portal-mobile-top{display:flex;align-items:center;justify-content:space-between;gap:14px;min-height:68px;background:#fff;border:1px solid var(--line);border-radius:22px;padding:12px 14px;margin-bottom:20px;box-shadow:0 14px 35px rgba(15,23,42,.055);position:sticky;top:10px;z-index:20}.portal-mobile-top div{display:grid;gap:2px;text-align:right}.portal-mobile-top strong{font-size:15px}.portal-mobile-top small{color:var(--muted);font-size:12px}.portal-summary-grid{grid-template-columns:1fr}.portal-main{padding:0}.portal-nav-vertical a{padding:14px}.portal-sidebar-bottom .btn{width:100%}}
@media(max-width:700px){.table-actions{display:grid;grid-template-columns:1fr;min-width:0;width:100%}.table-actions .action-row{display:grid;grid-template-columns:1fr 1fr;width:100%}.table-actions .action-row form,.table-actions .action-row .btn{width:100%}.doc-upload-cell{min-width:0}.auto-upload{max-width:none;width:100%}.payments-admin-table td:last-child{background:#fff}.portal-summary-grid{gap:14px}.year-row{align-items:flex-start;flex-direction:column;gap:4px}.year-row.total{align-items:flex-start}.year-row.total strong{font-size:24px}.portal-actions-card .actions{display:grid;grid-template-columns:1fr;width:100%}}
.portal-sidebar{display:flex;flex-direction:column}

/* v1.0.11 manual emails */
.email-builder-grid{align-items:start}.email-builder{overflow:visible}.language-editor-grid{margin-top:22px}.language-card{background:var(--panel-soft);border:1px solid var(--line);border-radius:20px;padding:18px;display:grid;gap:14px}.section-title.compact{padding-bottom:10px;margin-bottom:4px}.section-title.compact h2{font-size:18px}.language-card textarea{min-height:260px;line-height:1.55}.email-hint{margin-top:18px}.is-muted{opacity:.58}.is-muted select{background:#f3f4f6}.kpi-note{display:block;margin-top:6px;color:var(--muted);font-size:12px;font-weight:750;line-height:1.35}.page-btn.active{background:var(--primary);color:#fff;border-color:var(--primary)}.table-pagination{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-top:12px}.pagination-info{color:var(--muted);font-size:13px;font-weight:800}.pagination-controls{display:flex;align-items:center;gap:6px;flex-wrap:wrap}
@media(max-width:900px){.email-builder .form-grid,.language-editor-grid{grid-template-columns:1fr}.language-card textarea{min-height:220px}.table-pagination{align-items:flex-start;flex-direction:column}.pagination-controls{width:100%;display:grid;grid-template-columns:repeat(3,minmax(0,1fr))}.pagination-controls .btn{width:100%}}

/* v1.0.12 manual email composer cleanup */
.email-compose-shell{max-width:1320px;margin:0 auto}.email-compose-card{padding:0;overflow:hidden}.email-compose-header{display:flex;align-items:center;justify-content:space-between;gap:22px;padding:clamp(20px,2.2vw,30px);border-bottom:1px solid var(--line);background:linear-gradient(135deg,#fff 0%,#fbfcff 100%)}.email-compose-header h2{margin:8px 0 6px;font-size:clamp(24px,3vw,34px);letter-spacing:-.045em}.email-compose-badge{display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;padding:10px 13px;border-radius:999px;background:#111827;color:#fff;font-size:12px;font-weight:950;letter-spacing:.06em}.email-control-panel{display:grid;grid-template-columns:minmax(280px,1.35fr) minmax(220px,.85fr) minmax(200px,.7fr);gap:16px;padding:clamp(18px,2vw,26px);background:#fff;border-bottom:1px solid var(--line)}.email-control-panel label{margin:0}.recipient-field select{font-weight:850}.template-date-panel{display:grid;grid-template-columns:minmax(220px,.9fr) minmax(180px,.55fr) minmax(180px,.55fr);gap:16px;align-items:end;margin:0 clamp(18px,2vw,26px) 0;padding:18px;border:1px solid #f1dfbd;background:var(--accent-soft);border-radius:18px}.template-date-panel[hidden]{display:none!important}.template-date-panel strong{display:block;font-size:15px}.template-date-panel small{display:block;margin-top:4px;color:#7c5d28;font-weight:750;line-height:1.4}.email-editor-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;padding:clamp(18px,2vw,26px);background:#f8fafc}.email-language-card{margin:0;background:#fff;border-radius:22px;padding:20px;box-shadow:none}.language-card-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:16px;padding-bottom:14px;border-bottom:1px solid var(--line)}.language-card-head h2{margin:0 0 4px;font-size:21px}.language-card-head p{margin:0}.language-card-head span{display:inline-grid;place-items:center;width:42px;height:42px;border-radius:15px;background:#111827;color:#fff;font-weight:950}.email-language-card textarea{min-height:235px;line-height:1.5}.compact-hint{margin:0 clamp(18px,2vw,26px) clamp(18px,2vw,26px);background:#fff}.email-compose-card .sticky-actions{margin:0 clamp(18px,2vw,26px) clamp(18px,2vw,26px)}@media(max-width:1040px){.email-control-panel{grid-template-columns:1fr 1fr}.email-control-panel .recipient-field{grid-column:1/-1}.template-date-panel{grid-template-columns:1fr 1fr}.template-date-panel>div{grid-column:1/-1}.email-editor-grid{grid-template-columns:1fr}}@media(max-width:640px){.email-compose-header{align-items:flex-start;flex-direction:column}.email-compose-badge{width:100%}.email-control-panel,.template-date-panel,.email-editor-grid{grid-template-columns:1fr;padding:16px;margin-left:0;margin-right:0;border-radius:0;border-left:0;border-right:0}.email-language-card{border-radius:18px;padding:16px}.email-language-card textarea{min-height:220px}.compact-hint,.email-compose-card .sticky-actions{margin-left:16px;margin-right:16px}.email-compose-card .sticky-actions{display:grid;grid-template-columns:1fr}.email-compose-card .sticky-actions .btn{width:100%}}


/* v1.0.14 global filters */
.filter-card{padding:18px;margin-bottom:20px;background:linear-gradient(135deg,#fff 0%,#fbfcff 100%)}.filter-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:15px;padding-bottom:13px;border-bottom:1px solid var(--line)}.filter-head strong{display:block;font-size:16px;letter-spacing:-.02em}.filter-head small{display:block;margin-top:4px;color:var(--muted);font-weight:700;line-height:1.35}.filter-count{display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;border:1px solid #f1dfbd;background:var(--accent-soft);color:#8a5f1b;border-radius:999px;padding:7px 10px;font-size:12px;font-weight:950}.filter-grid{display:grid;gap:14px;align-items:end}.filter-grid.three{grid-template-columns:repeat(3,minmax(0,1fr))}.filter-grid.four{grid-template-columns:1.5fr 1fr 1fr auto}.filter-grid.five{grid-template-columns:1.4fr 1fr 1fr 1fr 1fr}.filter-grid.six{grid-template-columns:1.35fr 1fr 1fr 1fr 1fr auto}.filter-grid.seven{grid-template-columns:1.35fr 1.2fr .9fr .9fr 1.1fr .9fr .9fr}.filter-actions{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex-wrap:wrap;margin-top:14px}.filter-actions.inline{margin-top:0;align-self:end}.filter-card label{font-size:13px;gap:7px}.filter-card input,.filter-card select{min-height:44px;padding:10px 12px;border-radius:13px;background:#fff}.table-section-title{display:flex;align-items:flex-start;justify-content:space-between;gap:16px}.security-filter-card{margin-top:20px;margin-bottom:14px}.dashboard-filter{margin-top:-8px}.portal-filter-card{box-shadow:none;border-color:#dbe3ef}.portal-filter-card .filter-head{margin-bottom:12px}.portal-filter-card .filter-head strong{font-size:15px}@media(max-width:1180px){.filter-grid.five,.filter-grid.six,.filter-grid.seven{grid-template-columns:repeat(3,minmax(0,1fr))}.filter-actions.inline{grid-column:auto}}@media(max-width:760px){.filter-head{flex-direction:column;gap:10px}.filter-grid,.filter-grid.three,.filter-grid.four,.filter-grid.five,.filter-grid.six,.filter-grid.seven{grid-template-columns:1fr}.filter-actions,.filter-actions.inline{justify-content:stretch;margin-top:4px}.filter-actions .btn{width:100%}.table-section-title{display:block}.filter-card{padding:15px;border-radius:18px}}

/* v1.0.15 client dashboard/profile/table refinements */
.portal-summary-grid-v2{grid-template-columns:minmax(260px,1.15fr) minmax(260px,1fr) minmax(185px,.72fr) minmax(185px,.72fr)}
.portal-plan-card .mini-metric{margin-top:14px;padding-top:12px;border-top:1px solid var(--line);font-size:13px}
.portal-company-line{margin-top:-2px!important;color:var(--muted)}
.portal-payment-kpi strong{font-size:clamp(24px,3vw,32px)}
.portal-actions-card{margin-top:4px}
.portal-payments-table th:first-child,.portal-payments-table td:first-child{min-width:300px;width:300px;max-width:420px;white-space:normal;word-break:normal;overflow-wrap:break-word}
.profile-form input[readonly]{background:#f8fafc;color:#6b7280;cursor:not-allowed}
.profile-admin-warning{margin:2px 0 0}
@media(max-width:1180px){.portal-summary-grid-v2{grid-template-columns:1fr 1fr}.portal-summary-grid-v2 .portal-plan-card,.portal-summary-grid-v2 .yearly-breakdown{grid-column:auto}}
@media(max-width:700px){.portal-summary-grid-v2{grid-template-columns:1fr}.table-wrap{border:1px solid var(--line);background:#fff;overflow-x:auto;overflow-y:hidden;-webkit-overflow-scrolling:touch;border-radius:18px}table.data-table{display:table!important;min-width:760px;width:100%;border-collapse:separate;border-spacing:0}.data-table thead{display:table-header-group!important}.data-table tbody{display:table-row-group!important}.data-table tr{display:table-row!important;background:transparent!important;border:0!important;border-radius:0!important;margin:0!important;box-shadow:none!important;overflow:visible!important}.data-table th,.data-table td{display:table-cell!important;text-align:left!important;vertical-align:middle!important;padding:14px 15px!important;border-bottom:1px solid var(--line)!important}.data-table td::before{content:none!important;display:none!important}.data-table td:last-child{border-bottom:1px solid var(--line)!important}.data-table tr:last-child td{border-bottom:0!important}.data-table .actions{justify-content:flex-start}.portal-payments-table{min-width:980px!important}.portal-payments-table th:first-child,.portal-payments-table td:first-child{min-width:300px;width:300px}.clients-admin-table,.payments-admin-table{min-width:1020px!important}.documents-admin-table,.costs-admin-table,.plans-admin-table{min-width:900px!important}.table-wrap::after{content:'Arraste para ver mais';display:block;position:sticky;left:0;bottom:0;padding:8px 12px;background:linear-gradient(90deg,#fff,rgba(255,255,255,.84));color:var(--muted);font-size:11px;font-weight:850;text-transform:uppercase;letter-spacing:.05em}.portal-actions-card .actions{display:grid;grid-template-columns:1fr;width:100%}.portal-actions-card .btn{width:100%}}
@media(max-width:480px){.data-table .actions .btn,.data-table .actions form{width:auto}.data-table .actions{display:flex;flex-wrap:wrap;min-width:160px}.data-table .btn.small{white-space:nowrap}}

/* v1.0.16 - mobile filters and client dashboard payment summary */
.portal-summary-grid-v2{grid-template-columns:minmax(260px,1.15fr) minmax(260px,1fr) minmax(260px,.95fr)!important}
.portal-payments-summary-card{display:flex;flex-direction:column;justify-content:space-between;gap:14px}
.portal-payments-summary-card>.eyebrow{align-self:flex-start}
.payment-split-metrics{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-top:6px}
.payment-split-metrics>div{background:#f9fafb;border:1px solid var(--line);border-radius:16px;padding:14px;min-width:0}
.payment-split-metrics small{display:block;color:var(--muted);font-size:11px;font-weight:950;text-transform:uppercase;letter-spacing:.06em;line-height:1.25;margin-bottom:7px}
.payment-split-metrics strong{display:block;font-size:clamp(21px,2.6vw,30px);line-height:1.05;letter-spacing:-.045em;white-space:nowrap}
@media(max-width:1180px){.portal-summary-grid-v2{grid-template-columns:1fr 1fr!important}.portal-payments-summary-card{grid-column:1/-1}}
@media(max-width:700px){.portal-summary-grid-v2{grid-template-columns:1fr!important}.payment-split-metrics{grid-template-columns:1fr 1fr}.payment-split-metrics strong{font-size:20px}}
@media(max-width:430px){.payment-split-metrics{grid-template-columns:1fr}}
@media(max-width:760px) and (min-width:431px){.filter-grid,.filter-grid.three,.filter-grid.four,.filter-grid.five,.filter-grid.six,.filter-grid.seven{grid-template-columns:repeat(2,minmax(0,1fr))!important}.filter-grid label{min-width:0}.filter-grid label:has(input[type="search"]),.filter-grid label:has(input[name="q"]),.filter-grid label:has(input[name="search"]),.filter-grid label.mobile-full{grid-column:1/-1}.filter-actions,.filter-actions.inline{grid-column:1/-1;display:grid;grid-template-columns:1fr 1fr;gap:8px;justify-content:stretch;margin-top:4px}.filter-actions .btn{width:100%}}
@media(max-width:430px){.filter-grid,.filter-grid.three,.filter-grid.four,.filter-grid.five,.filter-grid.six,.filter-grid.seven{grid-template-columns:1fr!important}.filter-actions,.filter-actions.inline{display:grid;grid-template-columns:1fr;gap:8px}}

/* v1.0.17 - polished mobile filters and client payment summary */
.portal-payments-summary-card{min-height:0!important;justify-content:flex-start!important}
.payment-split-metrics{display:grid!important;grid-template-columns:1fr!important;gap:10px!important;margin-top:8px!important}
.payment-split-metrics>div{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:16px!important;background:#f9fafb;border:1px solid var(--line);border-radius:16px;padding:13px 14px!important;min-height:58px}
.payment-split-metrics small{margin:0!important;max-width:52%;font-size:11px!important;line-height:1.25!important;color:var(--muted);font-weight:950;text-transform:uppercase;letter-spacing:.055em}
.payment-split-metrics strong{font-size:clamp(22px,3vw,30px)!important;line-height:1!important;white-space:nowrap;text-align:right;letter-spacing:-.045em}
@media(max-width:700px){.portal-payments-summary-card{padding-bottom:20px!important}.payment-split-metrics{grid-template-columns:1fr!important}.payment-split-metrics>div{min-height:62px}.payment-split-metrics strong{font-size:26px!important}}
@media(max-width:760px) and (min-width:431px){.filter-grid label.mobile-orphan-full{grid-column:1/-1!important}.filter-card{padding:16px 18px 22px!important}.filter-actions,.filter-actions.inline{margin-top:10px!important;margin-bottom:6px!important}.filter-actions .btn{min-height:44px}}
@media(max-width:430px){.filter-card{padding-bottom:22px!important}.filter-actions,.filter-actions.inline{margin-top:10px!important;margin-bottom:6px!important}.filter-actions .btn{min-height:44px}.payment-split-metrics>div{align-items:flex-start!important;flex-direction:column!important;gap:8px!important}.payment-split-metrics small{max-width:100%}.payment-split-metrics strong{text-align:left!important}}

/* v1.0.18 - safer value stacking for large dashboard amounts */
.yearly-breakdown{align-content:start!important}
.year-row{display:flex!important;flex-direction:column!important;align-items:flex-start!important;justify-content:flex-start!important;gap:6px!important;min-width:0!important}
.year-row span{display:block!important;width:100%!important;font-size:clamp(12px,1.45vw,15px)!important;line-height:1.25!important;text-transform:none!important}
.year-row strong{display:block!important;width:100%!important;max-width:100%!important;font-size:clamp(23px,3.2vw,31px)!important;line-height:1.08!important;letter-spacing:-.045em!important;white-space:normal!important;overflow-wrap:anywhere!important;word-break:normal!important}
.year-row.total{gap:8px!important;padding:18px!important}
.year-row.total strong{font-size:clamp(26px,3.8vw,36px)!important;line-height:1.06!important}
.payment-split-metrics>div{display:flex!important;flex-direction:column!important;align-items:flex-start!important;justify-content:flex-start!important;gap:7px!important;min-width:0!important;min-height:0!important;padding:16px 18px!important}
.payment-split-metrics small{max-width:none!important;width:100%!important;margin:0!important;font-size:clamp(10px,1.25vw,12px)!important;line-height:1.2!important}
.payment-split-metrics strong{display:block!important;width:100%!important;max-width:100%!important;text-align:left!important;font-size:clamp(24px,3.5vw,34px)!important;line-height:1.08!important;white-space:normal!important;overflow-wrap:anywhere!important;word-break:normal!important}
@media(max-width:700px){.year-row strong{font-size:clamp(25px,8vw,34px)!important}.year-row.total strong{font-size:clamp(29px,9vw,38px)!important}.payment-split-metrics strong{font-size:clamp(28px,8.5vw,38px)!important}.payment-split-metrics>div{padding:16px!important}.portal-payments-summary-card{padding-bottom:22px!important}}

/* v1.0.19 - contract annual renewal model */
.block{display:block;margin-top:4px}.danger-text{color:var(--danger)!important}.danger-zone{border-color:rgba(220,38,38,.22);background:linear-gradient(180deg,#fff,#fff7f7)}.btn.warning{background:#fff7ed;border-color:#fed7aa;color:#9a3412}.btn.warning:hover{background:#ffedd5}.badge.inactive{background:#f3f4f6;color:#4b5563}.plans-admin-table td .muted.block{font-size:11px;line-height:1.25}.form-grid input[readonly]{background:#f8fafc;color:#6b7280;cursor:not-allowed}

/* v1.0.24 - plan total includes annual extras */
.plan-summary-cards{grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch}
.plan-summary-cards .kpi{margin-bottom:0;min-width:0}
.plan-summary-cards .kpi strong{max-width:100%;white-space:normal;overflow-wrap:anywhere;line-height:1.08}
.plan-summary-cards .kpi-note{display:block;margin-top:8px;color:var(--muted);font-size:12px;line-height:1.35;font-weight:700}
.plans-admin-table th:nth-child(4),.plans-admin-table td:nth-child(4),.plans-admin-table th:nth-child(5),.plans-admin-table td:nth-child(5){white-space:nowrap}
@media(max-width:700px){.plan-summary-cards{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:12px}.plan-summary-cards .card{padding:16px!important}.plan-summary-cards .kpi span{font-size:10px;line-height:1.2}.plan-summary-cards .kpi strong{font-size:clamp(22px,7vw,30px)!important}.plans-admin-table{min-width:1120px!important}}
@media(max-width:360px){.plan-summary-cards{grid-template-columns:1fr!important}}

/* v1.0.25 - keep payment reference columns readable */
.payments-admin-table th:nth-child(2),
.payments-admin-table td:nth-child(2),
.portal-payments-table th:first-child,
.portal-payments-table td:first-child {
    min-width: 300px;
    width: 300px;
    max-width: 440px;
    white-space: normal;
    word-break: normal;
    overflow-wrap: break-word;
}
.payments-admin-table td:nth-child(2) .table-main-text,
.portal-payments-table td:first-child strong {
    max-width: none;
    white-space: normal;
    word-break: normal;
    overflow-wrap: break-word;
}
@media (max-width: 700px) {
    .payments-admin-table th:nth-child(2),
    .payments-admin-table td:nth-child(2),
    .portal-payments-table th:first-child,
    .portal-payments-table td:first-child {
        min-width: 300px !important;
        width: 300px !important;
        max-width: 440px;
    }
}

/* v1.0.26 - desktop collapsible sidebar rail */
.sidebar-head-actions{display:flex;align-items:center;gap:8px;flex:0 0 auto}
.sidebar-collapse-toggle,.desktop-sidebar-toggle{display:inline-flex;align-items:center;justify-content:center;width:40px;height:40px;border:1px solid rgba(255,255,255,.12);border-radius:14px;background:rgba(255,255,255,.08);color:#fff;cursor:pointer;font-weight:950;line-height:1;transition:background .15s,transform .15s,border-color .15s}
.sidebar-collapse-toggle:hover{background:rgba(255,255,255,.14);border-color:rgba(197,157,95,.34)}
.sidebar-collapse-toggle span{display:block;font-size:25px;line-height:1;transform:translateX(-1px);transition:transform .18s ease}
.desktop-sidebar-toggle{display:inline-flex;border-color:var(--line);background:#fff;color:var(--primary);font-size:18px;box-shadow:0 10px 22px rgba(15,23,42,.04)}
.desktop-sidebar-toggle:hover{background:#f8fafc}
.nav-icon{width:28px;height:28px;min-width:28px;border-radius:11px;display:inline-grid;place-items:center;background:rgba(255,255,255,.07);color:#f8fafc;font-weight:950;font-size:14px;line-height:1}
.nav-submenu a.active .nav-icon,.portal-nav-vertical a.active span{background:rgba(197,157,95,.22);color:#fff}
.portal-nav-vertical a em{font-style:normal;min-width:0}
@media(min-width:921px){
    .sidebar{transition:width .22s ease,padding .22s ease,box-shadow .22s ease}
    .admin-main,.portal-content{transition:padding .22s ease}
    body.sidebar-collapsed .sidebar{width:86px;padding:20px 12px}
    body.sidebar-collapsed .portal-sidebar{width:86px;flex-basis:86px;padding-left:12px;padding-right:12px}
    body.sidebar-collapsed .sidebar-head{align-items:center;justify-content:center;margin-bottom:20px;gap:10px;flex-direction:column}
    body.sidebar-collapsed .brand,body.sidebar-collapsed .portal-brand{justify-items:center;text-align:center;width:100%}
    body.sidebar-collapsed .brand span,body.sidebar-collapsed .portal-brand span{font-size:18px;letter-spacing:-.04em;max-width:56px;overflow:hidden;white-space:nowrap;text-overflow:clip}
    body.sidebar-collapsed .brand small,body.sidebar-collapsed .portal-brand small{display:none}
    body.sidebar-collapsed .sidebar-head-actions{justify-content:center;width:100%}
    body.sidebar-collapsed .sidebar-collapse-toggle span{transform:rotate(180deg) translateX(-1px)}
    body.sidebar-collapsed .nav-group{padding-top:10px;border-top:1px solid rgba(255,255,255,.08)}
    body.sidebar-collapsed .nav-group:first-child{border-top:0;padding-top:0}
    body.sidebar-collapsed .nav-toggle{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
    body.sidebar-collapsed .nav-submenu{display:grid!important;gap:9px}
    body.sidebar-collapsed .nav-submenu a{justify-content:center;padding:10px;border-radius:16px;min-height:44px;position:relative}
    body.sidebar-collapsed .nav-submenu a .nav-label{position:absolute;left:calc(100% + 12px);top:50%;transform:translateY(-50%) translateX(-4px);opacity:0;pointer-events:none;background:#111827;color:#fff;border:1px solid rgba(255,255,255,.10);box-shadow:0 16px 38px rgba(15,23,42,.20);border-radius:12px;padding:8px 10px;white-space:nowrap;font-size:12px;font-weight:900;z-index:80;transition:opacity .14s ease,transform .14s ease}
    body.sidebar-collapsed .nav-submenu a:hover .nav-label,body.sidebar-collapsed .nav-submenu a:focus-visible .nav-label{opacity:1;transform:translateY(-50%) translateX(0)}
    body.sidebar-collapsed .portal-client-card{display:grid;place-items:center;padding:12px;margin-bottom:18px;min-height:46px;border-radius:16px}
    body.sidebar-collapsed .portal-client-card span,body.sidebar-collapsed .portal-client-card strong{display:none}
    body.sidebar-collapsed .portal-client-card:before{content:'◎';font-weight:950;color:#fff;font-size:18px;line-height:1}
    body.sidebar-collapsed .portal-nav-vertical a{justify-content:center;padding:11px;border-radius:16px;min-height:46px;position:relative}
    body.sidebar-collapsed .portal-nav-vertical a span{margin:0;width:30px;height:30px;min-width:30px}
    body.sidebar-collapsed .portal-nav-vertical a em{position:absolute;left:calc(100% + 12px);top:50%;transform:translateY(-50%) translateX(-4px);opacity:0;pointer-events:none;background:#111827;color:#fff;border:1px solid rgba(255,255,255,.10);box-shadow:0 16px 38px rgba(15,23,42,.20);border-radius:12px;padding:8px 10px;white-space:nowrap;font-size:12px;font-weight:900;z-index:80;transition:opacity .14s ease,transform .14s ease}
    body.sidebar-collapsed .portal-nav-vertical a:hover em,body.sidebar-collapsed .portal-nav-vertical a:focus-visible em{opacity:1;transform:translateY(-50%) translateX(0)}
    body.sidebar-collapsed .portal-sidebar-bottom .btn{font-size:0;padding:11px;width:100%;min-height:44px;border-radius:16px}
    body.sidebar-collapsed .portal-sidebar-bottom .btn:before{content:'↪';font-size:18px;font-weight:950;line-height:1}
}
@media(max-width:920px){
    .desktop-sidebar-toggle,.sidebar-collapse-toggle{display:none!important}
    .sidebar-head-actions{gap:0}
}

/* v1.0.27 - sidebar scroll + compact menu spacing */
@media (min-width: 921px) {
    .sidebar {
        display: flex !important;
        flex-direction: column !important;
        overflow: hidden !important;
        min-height: 100vh;
        max-height: 100vh;
    }

    .sidebar-head {
        flex: 0 0 auto;
        margin-bottom: 16px !important;
    }

    .admin-nav,
    .portal-nav-vertical {
        flex: 1 1 auto !important;
        min-height: 0 !important;
        overflow-y: auto !important;
        overflow-x: visible !important;
        padding-right: 4px;
        scrollbar-width: thin;
        scrollbar-color: rgba(255,255,255,.24) transparent;
    }

    .admin-nav::-webkit-scrollbar,
    .portal-nav-vertical::-webkit-scrollbar {
        width: 7px;
    }

    .admin-nav::-webkit-scrollbar-thumb,
    .portal-nav-vertical::-webkit-scrollbar-thumb {
        background: rgba(255,255,255,.22);
        border-radius: 999px;
    }

    .admin-nav::-webkit-scrollbar-track,
    .portal-nav-vertical::-webkit-scrollbar-track {
        background: transparent;
    }

    .portal-client-card {
        flex: 0 0 auto;
        margin-bottom: 14px !important;
        padding: 13px 14px !important;
    }

    .portal-sidebar-bottom {
        flex: 0 0 auto;
        margin-top: 12px !important;
        padding-top: 12px !important;
        border-top: 1px solid rgba(255,255,255,.08);
    }
}

.admin-nav {
    gap: 9px !important;
}

.nav-group {
    padding-top: 8px !important;
}

.nav-toggle {
    padding: 3px 4px 6px !important;
    font-size: 10px !important;
    letter-spacing: .10em !important;
}

.nav-submenu {
    gap: 4px !important;
}

.nav-submenu a {
    padding: 10px 12px !important;
    border-radius: 13px !important;
    gap: 9px !important;
    line-height: 1.15 !important;
}

.nav-icon {
    width: 26px !important;
    height: 26px !important;
    min-width: 26px !important;
    border-radius: 10px !important;
}

.portal-nav-vertical {
    gap: 5px !important;
}

.portal-nav-vertical a {
    padding: 10px 12px !important;
    border-radius: 13px !important;
    gap: 10px !important;
    line-height: 1.15 !important;
}

.portal-nav-vertical a span {
    width: 25px !important;
    height: 25px !important;
    min-width: 25px !important;
    border-radius: 10px !important;
}

@media (min-width: 921px) {
    body.sidebar-collapsed .admin-nav,
    body.sidebar-collapsed .portal-nav-vertical {
        padding-right: 0 !important;
        overflow-x: visible !important;
    }

    body.sidebar-collapsed .nav-submenu {
        gap: 6px !important;
    }

    body.sidebar-collapsed .nav-submenu a,
    body.sidebar-collapsed .portal-nav-vertical a {
        min-height: 42px !important;
        padding: 9px !important;
        border-radius: 14px !important;
    }

    body.sidebar-collapsed .nav-icon,
    body.sidebar-collapsed .portal-nav-vertical a span {
        width: 29px !important;
        height: 29px !important;
        min-width: 29px !important;
    }

    body.sidebar-collapsed .portal-client-card {
        margin-bottom: 12px !important;
        padding: 10px !important;
        min-height: 42px !important;
    }

    body.sidebar-collapsed .portal-sidebar-bottom {
        margin-top: 10px !important;
        padding-top: 10px !important;
    }
}

@media (max-width: 920px) {
    .sidebar {
        display: flex !important;
        flex-direction: column !important;
        overflow: hidden !important;
    }

    .admin-nav,
    .portal-nav-vertical {
        flex: 1 1 auto !important;
        min-height: 0 !important;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        padding-right: 4px;
    }

    .sidebar-head {
        flex: 0 0 auto;
        margin-bottom: 16px !important;
    }

    .portal-client-card {
        flex: 0 0 auto;
        margin-bottom: 14px !important;
    }

    .portal-sidebar-bottom {
        flex: 0 0 auto;
        margin-top: 12px !important;
        padding-top: 12px !important;
        border-top: 1px solid rgba(255,255,255,.08);
    }

    .nav-submenu a,
    .portal-nav-vertical a {
        padding-top: 11px !important;
        padding-bottom: 11px !important;
    }
}

/* v1.0.28 payment file handling */
.payment-doc-section-title{margin-top:6px}.payment-current-docs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;padding:12px;border:1px solid var(--line);border-radius:18px;background:#f8fafc}.payment-current-docs>div{display:grid;gap:8px}.doc-link-row{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.inline-delete-doc{display:inline-flex;margin:0}.btn.tiny{min-height:26px;padding:5px 8px;font-size:11px;border-radius:10px}.payment-reference-text{min-width:300px;max-width:420px;white-space:normal;overflow-wrap:break-word}.payments-admin-table th:nth-child(2),.payments-admin-table td:nth-child(2),.portal-payments-table th:nth-child(1),.portal-payments-table td:nth-child(1){min-width:300px}.doc-upload-cell .badge.cancelled{display:inline-flex;margin-bottom:4px}.doc-upload-cell{min-width:260px}@media(max-width:700px){.payment-current-docs{grid-template-columns:1fr}.payment-reference-text{min-width:280px;max-width:none}.payments-admin-table th:nth-child(2),.payments-admin-table td:nth-child(2),.portal-payments-table th:nth-child(1),.portal-payments-table td:nth-child(1){min-width:300px}.doc-link-row{align-items:flex-start}}

/* v1.0.29 - annual fixed costs + dashboard mobile tables */
.grid > .card{min-width:0}.cost-entry-grid>.card{min-width:0}.cost-summary-cards{grid-template-columns:repeat(auto-fit,minmax(190px,1fr))}.annual-costs-table{min-width:900px}.dashboard-tables>.card{min-width:0;overflow:hidden}.dashboard-table-wrap{max-width:100%;overflow-x:auto;overflow-y:hidden;-webkit-overflow-scrolling:touch}.dashboard-admin-table{min-width:720px}.cost-entry-grid .section-title{grid-column:1/-1}.cost-entry-grid .section-title p{margin-bottom:0}
@media(max-width:920px){.dashboard-tables{grid-template-columns:1fr!important}.dashboard-tables>.card{width:100%}}
@media(max-width:700px){.dashboard-table-wrap{border:1px solid var(--line)!important;background:#fff!important;overflow-x:auto!important;overflow-y:hidden!important;border-radius:18px!important}.dashboard-admin-table{display:table!important;min-width:720px!important;width:100%!important}.dashboard-admin-table thead{display:table-header-group!important}.dashboard-admin-table tbody{display:table-row-group!important}.dashboard-admin-table tr{display:table-row!important;background:transparent!important;border:0!important;border-radius:0!important;margin:0!important;box-shadow:none!important;overflow:visible!important}.dashboard-admin-table th,.dashboard-admin-table td{display:table-cell!important;text-align:left!important;vertical-align:middle!important;padding:14px 15px!important;border-bottom:1px solid var(--line)!important}.dashboard-admin-table td::before{content:none!important;display:none!important}.dashboard-table-wrap::after{content:'Arraste para ver mais';display:block;position:sticky;left:0;bottom:0;padding:8px 12px;background:linear-gradient(90deg,#fff,rgba(255,255,255,.84));color:var(--muted);font-size:11px;font-weight:850;text-transform:uppercase;letter-spacing:.05em}.cost-summary-cards{grid-template-columns:repeat(2,minmax(0,1fr))}.cost-summary-cards .card{padding:16px!important}.cost-summary-cards .kpi span{font-size:10px;line-height:1.2}.cost-summary-cards .kpi strong{font-size:clamp(21px,7vw,30px)!important}.cost-entry-grid{grid-template-columns:1fr!important}.annual-costs-table{min-width:860px!important}}
@media(max-width:360px){.cost-summary-cards{grid-template-columns:1fr!important}}

/* v1.0.30 - dashboard cards, compact tables and cleaner actions */
.dashboard-kpi-grid{grid-template-columns:repeat(4,minmax(0,1fr))!important;gap:18px!important}.dashboard-kpi-grid .card{margin-bottom:0}.kpi-highlight-soft{border-color:rgba(197,157,95,.46)!important;background:linear-gradient(180deg,#fff 0%,#fffbf3 100%);box-shadow:0 22px 55px rgba(138,95,27,.10)!important}.kpi-highlight-soft:after{background:linear-gradient(135deg,rgba(197,157,95,.28),rgba(197,157,95,0))!important}.data-table th,.data-table td{padding:10px 12px!important;line-height:1.25}.data-table td{min-height:auto!important}.data-table tbody tr{height:auto}.data-table .btn.small{min-height:29px!important;padding:6px 9px!important;border-radius:10px!important;font-size:11px!important}.data-table .badge{padding:5px 8px;font-size:11px}.data-table .actions,.data-table .table-actions,.compact-actions{display:flex!important;align-items:center!important;gap:6px!important;flex-wrap:nowrap!important;white-space:nowrap}.data-table .actions form,.data-table .table-actions form,.compact-actions form{display:inline-flex!important;margin:0!important;flex:0 0 auto}.data-table .actions .btn,.data-table .table-actions .btn,.compact-actions .btn{white-space:nowrap}.clients-admin-table th:first-child,.clients-admin-table td:first-child{min-width:250px}.plans-admin-table th:nth-child(2),.plans-admin-table td:nth-child(2){min-width:250px}.plans-admin-table td:nth-child(2) strong,.clients-admin-table td:first-child strong{display:inline-block;min-width:220px;white-space:normal;overflow-wrap:break-word}.doc-upload-cell{min-width:220px!important}.doc-compact-box{display:flex;align-items:center;gap:8px;flex-wrap:nowrap;white-space:nowrap}.doc-compact-status{display:inline-flex;align-items:center;gap:6px;flex:0 0 auto}.doc-compact-upload{display:inline-flex!important;grid-template-columns:none!important;margin:0!important;gap:0!important;align-items:center!important;flex:0 0 auto}.sr-only-file{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}.btn.tiny{min-height:24px!important;padding:4px 7px!important;font-size:10.5px!important;border-radius:9px!important}.payment-reference-text{min-width:300px;max-width:520px}.payments-admin-table th:nth-child(2),.payments-admin-table td:nth-child(2){min-width:300px!important}.payments-admin-table th:last-child,.payments-admin-table td:last-child,.plans-admin-table th:last-child,.plans-admin-table td:last-child,.clients-admin-table th:last-child,.clients-admin-table td:last-child{min-width:210px}.clients-admin-table th:last-child,.clients-admin-table td:last-child{min-width:310px}.plans-admin-table th:last-child,.plans-admin-table td:last-child{min-width:240px}.payments-admin-table th:last-child,.payments-admin-table td:last-child{min-width:260px}
@media(max-width:1180px){.dashboard-kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}}
@media(max-width:700px){.dashboard-kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:12px!important}.dashboard-kpi-grid .card{padding:15px!important}.dashboard-kpi-grid .kpi span{font-size:10px;line-height:1.2}.dashboard-kpi-grid .kpi strong{font-size:clamp(20px,7vw,29px)!important;word-break:break-word}.data-table th,.data-table td,.dashboard-admin-table th,.dashboard-admin-table td{padding:10px 12px!important}.data-table .actions,.data-table .table-actions,.compact-actions{flex-wrap:nowrap!important}.doc-compact-box{flex-wrap:nowrap}.doc-upload-cell{min-width:220px!important}.payments-admin-table{min-width:1180px!important}.clients-admin-table{min-width:1080px!important}.plans-admin-table{min-width:1240px!important}}
@media(max-width:380px){.dashboard-kpi-grid{grid-template-columns:1fr!important}}

/* v1.0.31 - financial correction, drag tables and navigation icon polish */
.nav-icon svg,
.portal-nav-vertical a .nav-icon svg{
    width:16px!important;
    height:16px!important;
    display:block!important;
    stroke:currentColor!important;
    fill:none!important;
    stroke-width:2!important;
    stroke-linecap:round!important;
    stroke-linejoin:round!important;
}
.nav-icon{
    color:inherit!important;
    font-size:0!important;
}
.nav-submenu a .nav-label,
.portal-nav-vertical a em{
    line-height:1.15!important;
}
.payments-admin-table th:last-child,
.payments-admin-table td:last-child,
.plans-admin-table th:last-child,
.plans-admin-table td:last-child{
    position:static!important;
    right:auto!important;
    left:auto!important;
    background:transparent!important;
    box-shadow:none!important;
}
.payments-admin-table th:last-child,
.payments-admin-table td:last-child{
    min-width:250px!important;
    width:auto!important;
}
.plans-admin-table th:last-child,
.plans-admin-table td:last-child{
    min-width:260px!important;
    width:auto!important;
}
.payments-admin-table td,
.plans-admin-table td,
.dashboard-admin-table td{
    vertical-align:middle!important;
}
.payments-admin-table .table-actions,
.plans-admin-table .table-actions,
.clients-admin-table .table-actions{
    display:inline-flex!important;
    align-items:center!important;
    gap:5px!important;
    flex-wrap:nowrap!important;
    min-width:0!important;
    width:max-content!important;
    max-width:none!important;
}
.payments-admin-table .table-actions .btn,
.plans-admin-table .table-actions .btn,
.clients-admin-table .table-actions .btn{
    min-width:0!important;
    padding-left:10px!important;
    padding-right:10px!important;
}
.payments-admin-table .table-actions form,
.plans-admin-table .table-actions form,
.clients-admin-table .table-actions form{
    flex:0 0 auto!important;
}
.drag-scroll-wrap{
    cursor:grab;
    -webkit-overflow-scrolling:touch;
    overscroll-behavior-x:contain;
}
.drag-scroll-wrap.is-dragging{
    cursor:grabbing!important;
    user-select:none!important;
}
.drag-scroll-wrap.is-dragging *{
    cursor:grabbing!important;
}
.dashboard-admin-table th:nth-child(2),
.dashboard-admin-table td:nth-child(2){
    white-space:nowrap;
}
.dashboard-admin-table td:nth-child(3){
    min-width:230px;
    max-width:360px;
    white-space:normal;
    overflow-wrap:break-word;
}
@media(max-width:700px){
    .payments-admin-table th:last-child,
    .payments-admin-table td:last-child{
        min-width:250px!important;
    }
    .plans-admin-table th:last-child,
    .plans-admin-table td:last-child{
        min-width:260px!important;
    }
    .payments-admin-table .table-actions,
    .plans-admin-table .table-actions,
    .clients-admin-table .table-actions{
        width:max-content!important;
    }
}


/* v1.0.32 - table overflow, compact actions and currency column stability */
html,
body{
    max-width:100%;
    overflow-x:hidden;
}
.admin-shell,
.admin-main,
.portal-shell,
.portal-content,
.portal-main,
.card,
.grid,
.table-wrap{
    min-width:0!important;
    max-width:100%!important;
}
.card:has(.table-wrap){
    overflow:hidden;
}
.table-wrap{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    overflow-x:auto!important;
    overflow-y:hidden!important;
    -webkit-overflow-scrolling:touch;
    overscroll-behavior-x:contain;
}
.table-wrap.drag-scroll-wrap{
    cursor:grab;
}
.table-wrap.drag-scroll-wrap.is-dragging{
    cursor:grabbing!important;
    user-select:none!important;
}
.table-wrap.drag-scroll-wrap.is-dragging *{
    cursor:grabbing!important;
}
.data-table{
    table-layout:auto!important;
}
.data-table th,
.data-table td{
    height:auto!important;
    vertical-align:middle!important;
}
/* Never turn table cells themselves into flex/grid containers. It breaks column sizing. */
.data-table td.actions,
.data-table td.table-actions,
.data-table td.compact-actions{
    display:table-cell!important;
    white-space:nowrap!important;
    width:auto!important;
    max-width:none!important;
}
.data-table td.actions > a,
.data-table td.actions > form,
.data-table td.table-actions > a,
.data-table td.table-actions > form,
.data-table td.compact-actions > a,
.data-table td.compact-actions > form{
    display:inline-flex!important;
    vertical-align:middle!important;
    margin:2px 4px 2px 0!important;
}
.data-table td.actions .btn,
.data-table td.table-actions .btn,
.data-table td.compact-actions .btn{
    white-space:nowrap!important;
}
/* Columns with amounts: enough room for at least 10.000,00 €. */
.plans-admin-table th:nth-child(3),
.plans-admin-table td:nth-child(3),
.plans-admin-table th:nth-child(4),
.plans-admin-table td:nth-child(4),
.plans-admin-table th:nth-child(5),
.plans-admin-table td:nth-child(5),
.payments-admin-table th:nth-child(3),
.payments-admin-table td:nth-child(3),
.portal-payments-table th:nth-child(2),
.portal-payments-table td:nth-child(2),
.costs-admin-table th:nth-child(5),
.costs-admin-table td:nth-child(5),
.annual-costs-table th:nth-child(2),
.annual-costs-table td:nth-child(2),
.dashboard-admin-table th:nth-child(2),
.dashboard-admin-table td:nth-child(2){
    min-width:145px!important;
    white-space:nowrap!important;
}
/* Preserve useful readable columns without forcing page-level overflow. */
.clients-admin-table th:first-child,
.clients-admin-table td:first-child,
.plans-admin-table th:nth-child(2),
.plans-admin-table td:nth-child(2){
    min-width:250px!important;
}
.payments-admin-table th:nth-child(2),
.payments-admin-table td:nth-child(2),
.portal-payments-table th:first-child,
.portal-payments-table td:first-child{
    min-width:300px!important;
}
.doc-upload-cell{
    min-width:360px!important;
}
.doc-compact-box{
    display:flex!important;
    align-items:center!important;
    gap:8px!important;
    flex-wrap:nowrap!important;
    white-space:nowrap!important;
}
.doc-compact-status{
    min-width:0!important;
}
/* Actions should be compact but not sticky/fixed. */
.payments-admin-table th:last-child,
.payments-admin-table td:last-child,
.plans-admin-table th:last-child,
.plans-admin-table td:last-child,
.clients-admin-table th:last-child,
.clients-admin-table td:last-child,
.costs-admin-table th:last-child,
.costs-admin-table td:last-child,
.annual-costs-table th:last-child,
.annual-costs-table td:last-child{
    position:static!important;
    right:auto!important;
    left:auto!important;
    min-width:240px!important;
    white-space:nowrap!important;
    background:transparent!important;
    box-shadow:none!important;
}
.payments-admin-table th:last-child,
.payments-admin-table td:last-child{
    min-width:220px!important;
}
.plans-admin-table th:last-child,
.plans-admin-table td:last-child{
    min-width:270px!important;
}
.clients-admin-table th:last-child,
.clients-admin-table td:last-child{
    min-width:300px!important;
}
/* Table minimums are intentionally internal to the table wrapper, not to the page. */
.payments-admin-table{min-width:1620px!important;}
.plans-admin-table{min-width:1420px!important;}
.clients-admin-table{min-width:1040px!important;}
.costs-admin-table{min-width:1120px!important;}
.annual-costs-table{min-width:980px!important;}
.documents-admin-table{min-width:900px!important;}
.portal-payments-table{min-width:1120px!important;}
@media(max-width:700px){
    .table-wrap{
        margin-left:0!important;
        margin-right:0!important;
        padding-bottom:2px;
    }
    .data-table th,
    .data-table td,
    .dashboard-admin-table th,
    .dashboard-admin-table td{
        padding:10px 12px!important;
    }
    .doc-upload-cell{
        min-width:340px!important;
    }
    .payments-admin-table{min-width:1540px!important;}
    .plans-admin-table{min-width:1360px!important;}
}

/* v1.0.33 - sidebar recovery + balanced table columns */
@media (min-width: 921px) {
    .admin-body .admin-shell,
    .portal-body .portal-shell {
        display: flex !important;
        align-items: stretch !important;
        min-height: 100vh !important;
        width: 100% !important;
        overflow: visible !important;
    }

    .admin-body .sidebar,
    .portal-body .sidebar {
        position: sticky !important;
        top: 0 !important;
        align-self: flex-start !important;
        flex: 0 0 var(--sidebar) !important;
        width: var(--sidebar) !important;
        height: 100vh !important;
        min-height: 100vh !important;
        max-height: 100vh !important;
        display: flex !important;
        flex-direction: column !important;
        overflow: hidden !important;
        transform: none !important;
    }

    body.sidebar-collapsed .sidebar,
    body.sidebar-collapsed .portal-sidebar {
        flex-basis: 86px !important;
        width: 86px !important;
    }

    .admin-main,
    .portal-content {
        flex: 1 1 auto !important;
        min-width: 0 !important;
        overflow-x: clip !important;
    }
}

/* Keep sidebar scrollable internally without cutting the dark background. */
.sidebar .admin-nav,
.sidebar .portal-nav-vertical {
    min-height: 0 !important;
}

/* Tables: scroll inside the card, not the page. */
.card:has(.table-wrap) {
    overflow: hidden !important;
}
.table-wrap {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    scrollbar-gutter: stable;
}
.data-table {
    width: 100% !important;
    max-width: none !important;
}

/* Payment table: reduce exaggerated gaps while keeping readable columns. */
.payments-admin-table {
    min-width: 1320px !important;
}
.payments-admin-table th,
.payments-admin-table td {
    white-space: nowrap !important;
}
.payments-admin-table th:nth-child(1),
.payments-admin-table td:nth-child(1) { min-width: 130px !important; width: 130px !important; }
.payments-admin-table th:nth-child(2),
.payments-admin-table td:nth-child(2) { min-width: 300px !important; width: 320px !important; white-space: normal !important; }
.payments-admin-table th:nth-child(3),
.payments-admin-table td:nth-child(3) { min-width: 120px !important; width: 125px !important; }
.payments-admin-table th:nth-child(4),
.payments-admin-table td:nth-child(4) { min-width: 105px !important; width: 110px !important; }
.payments-admin-table th:nth-child(5),
.payments-admin-table td:nth-child(5) { min-width: 90px !important; width: 96px !important; }
.payments-admin-table th:nth-child(6),
.payments-admin-table td:nth-child(6) { min-width: 108px !important; width: 112px !important; }
.payments-admin-table th:nth-child(7),
.payments-admin-table td:nth-child(7) { min-width: 155px !important; width: 170px !important; }
.payments-admin-table th:nth-child(8),
.payments-admin-table td:nth-child(8) { min-width: 235px !important; width: 250px !important; }
.payments-admin-table th:nth-child(9),
.payments-admin-table td:nth-child(9) { min-width: 220px !important; width: 230px !important; }
.payments-admin-table .payment-reference-text {
    min-width: 300px !important;
    max-width: 320px !important;
    display: inline-block !important;
    white-space: normal !important;
    overflow-wrap: break-word !important;
}
.payments-admin-table .doc-upload-cell {
    min-width: 0 !important;
}
.payments-admin-table .doc-compact-box {
    width: max-content !important;
    max-width: 100% !important;
    gap: 6px !important;
}
.payments-admin-table .doc-compact-status {
    gap: 5px !important;
}
.payments-admin-table .btn.tiny,
.payments-admin-table .btn.small {
    padding-left: 8px !important;
    padding-right: 8px !important;
}

/* Plans table: stable action column and sane column widths. */
.plans-admin-table {
    min-width: 1280px !important;
}
.plans-admin-table th:nth-child(1),
.plans-admin-table td:nth-child(1) { min-width: 160px !important; width: 170px !important; }
.plans-admin-table th:nth-child(2),
.plans-admin-table td:nth-child(2) { min-width: 250px !important; width: 280px !important; }
.plans-admin-table th:nth-child(3),
.plans-admin-table td:nth-child(3),
.plans-admin-table th:nth-child(4),
.plans-admin-table td:nth-child(4),
.plans-admin-table th:nth-child(5),
.plans-admin-table td:nth-child(5) { min-width: 125px !important; width: 130px !important; white-space: nowrap !important; }
.plans-admin-table th:nth-child(6),
.plans-admin-table td:nth-child(6) { min-width: 115px !important; width: 120px !important; white-space: nowrap !important; }
.plans-admin-table th:nth-child(7),
.plans-admin-table td:nth-child(7) { min-width: 170px !important; width: 180px !important; }
.plans-admin-table th:nth-child(8),
.plans-admin-table td:nth-child(8) { min-width: 70px !important; width: 75px !important; text-align:center !important; }
.plans-admin-table th:nth-child(9),
.plans-admin-table td:nth-child(9) { min-width: 90px !important; width: 100px !important; }
.plans-admin-table th:nth-child(10),
.plans-admin-table td:nth-child(10) { min-width: 250px !important; width: 255px !important; white-space: nowrap !important; }

/* Action cells: compact rows without fixed/sticky behavior. */
.data-table td.table-actions,
.data-table td.actions,
.data-table td.compact-actions {
    position: static !important;
    display: table-cell !important;
    background: transparent !important;
    box-shadow: none !important;
    white-space: nowrap !important;
}
.data-table td.table-actions > a,
.data-table td.table-actions > form,
.data-table td.actions > a,
.data-table td.actions > form,
.data-table td.compact-actions > a,
.data-table td.compact-actions > form {
    display: inline-flex !important;
    margin: 1px 3px 1px 0 !important;
    vertical-align: middle !important;
}
.data-table .btn.small {
    min-height: 30px !important;
    padding-top: 6px !important;
    padding-bottom: 6px !important;
}

@media (max-width: 700px) {
    .payments-admin-table { min-width: 1280px !important; }
    .plans-admin-table { min-width: 1240px !important; }
}

/* v1.0.33b - keep collapsed-sidebar labels from being clipped on desktop */
@media (min-width: 921px) {
    .admin-body .sidebar,
    .portal-body .sidebar {
        overflow: visible !important;
    }
    .admin-body .admin-nav,
    .portal-body .portal-nav-vertical {
        overflow-y: auto !important;
        overflow-x: visible !important;
    }
}

/* v1.0.35 - fixed sidebar, compact client menu, icon actions and tighter payment table */
.action-icon{display:inline-grid;place-items:center;width:16px;height:16px;line-height:1;flex:0 0 auto}
.action-icon svg{width:16px;height:16px;display:block;stroke:currentColor;fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.btn.icon-btn{width:34px!important;height:34px!important;min-width:34px!important;min-height:34px!important;padding:0!important;border-radius:11px!important;gap:0!important}
.btn.tiny.icon-btn{width:28px!important;height:28px!important;min-width:28px!important;min-height:28px!important;border-radius:9px!important}
.btn.icon-btn:hover{transform:translateY(-1px)}
.data-table td.actions > .btn.icon-btn,
.data-table td.actions > form,
.data-table td.table-actions > .btn.icon-btn,
.data-table td.table-actions > form,
.data-table td.compact-actions > .btn.icon-btn,
.data-table td.compact-actions > form{margin:1px 3px 1px 0!important}
.data-table td.actions form .btn.icon-btn,
.data-table td.table-actions form .btn.icon-btn,
.data-table td.compact-actions form .btn.icon-btn{margin:0!important}

@media (min-width: 921px){
    .admin-body .admin-shell,
    .portal-body .portal-shell{display:block!important;min-height:100vh!important;width:100%!important;overflow:visible!important}
    .admin-body .sidebar,
    .portal-body .sidebar{
        position:fixed!important;
        left:0!important;top:0!important;bottom:0!important;
        width:var(--sidebar)!important;
        height:100dvh!important;min-height:100dvh!important;max-height:100dvh!important;
        z-index:60!important;
        display:flex!important;flex-direction:column!important;
        overflow:visible!important;
        transform:none!important;
    }
    .portal-body .portal-sidebar{width:292px!important;flex-basis:292px!important}
    .admin-body .admin-main{margin-left:var(--sidebar)!important;width:calc(100% - var(--sidebar))!important;max-width:calc(100% - var(--sidebar))!important;overflow-x:clip!important}
    .portal-body .portal-content{margin-left:292px!important;width:calc(100% - 292px)!important;max-width:calc(100% - 292px)!important;overflow-x:clip!important}
    body.sidebar-collapsed .sidebar,
    body.sidebar-collapsed .portal-sidebar{width:86px!important;flex-basis:86px!important}
    body.sidebar-collapsed.admin-body .admin-main,
    body.sidebar-collapsed.portal-body .portal-content{margin-left:86px!important;width:calc(100% - 86px)!important;max-width:calc(100% - 86px)!important}
    .sidebar .admin-nav{flex:1 1 auto!important;min-height:0!important;overflow-y:auto!important;overflow-x:hidden!important;padding-right:5px!important;align-content:start!important}
    .sidebar .portal-nav-vertical{flex:0 1 auto!important;min-height:0!important;max-height:calc(100dvh - 260px)!important;overflow-y:auto!important;overflow-x:hidden!important;padding-right:4px!important;align-content:start!important;grid-auto-rows:min-content!important;align-items:start!important}
    body.sidebar-collapsed .sidebar .admin-nav,
    body.sidebar-collapsed .sidebar .portal-nav-vertical{overflow-x:visible!important;padding-right:0!important}
    .portal-sidebar-bottom{margin-top:auto!important;flex:0 0 auto!important;padding-top:12px!important}
}

/* Client portal menu: no oversized grid rows. */
.portal-client-card{padding:12px 14px!important;margin-bottom:14px!important;border-radius:17px!important}
.portal-client-card span{font-size:10px!important;letter-spacing:.075em!important}
.portal-client-card strong{font-size:14px!important;margin-top:4px!important}
.portal-nav-vertical{gap:4px!important;align-content:start!important;grid-auto-rows:min-content!important;align-items:start!important}
.portal-nav-vertical a{padding:9px 11px!important;min-height:40px!important;border-radius:13px!important;font-size:13px!important;gap:9px!important;align-items:center!important}
.portal-nav-vertical a .nav-icon,
.portal-nav-vertical a span{width:24px!important;height:24px!important;min-width:24px!important;border-radius:9px!important}
.portal-sidebar-bottom .btn{min-height:38px!important;padding:9px 12px!important;border-radius:13px!important;font-size:13px!important}
@media (max-width: 920px){
    .portal-nav-vertical a{padding:11px 12px!important;min-height:42px!important}
    .portal-client-card{padding:13px 14px!important}
}

/* Payment table: stop stretched columns; keep horizontal scroll inside wrapper. */
.payments-admin-table{width:max-content!important;min-width:1180px!important;table-layout:auto!important}
.payments-admin-table th,.payments-admin-table td{white-space:nowrap!important}
.payments-admin-table th:nth-child(1),.payments-admin-table td:nth-child(1){min-width:120px!important;width:120px!important;max-width:150px!important}
.payments-admin-table th:nth-child(2),.payments-admin-table td:nth-child(2){min-width:300px!important;width:300px!important;max-width:320px!important;white-space:normal!important}
.payments-admin-table th:nth-child(3),.payments-admin-table td:nth-child(3){min-width:130px!important;width:130px!important;white-space:nowrap!important}
.payments-admin-table th:nth-child(4),.payments-admin-table td:nth-child(4){min-width:100px!important;width:100px!important}
.payments-admin-table th:nth-child(5),.payments-admin-table td:nth-child(5){min-width:88px!important;width:88px!important}
.payments-admin-table th:nth-child(6),.payments-admin-table td:nth-child(6){min-width:105px!important;width:105px!important}
.payments-admin-table th:nth-child(7),.payments-admin-table td:nth-child(7){min-width:150px!important;width:150px!important}
.payments-admin-table th:nth-child(8),.payments-admin-table td:nth-child(8){min-width:205px!important;width:205px!important}
.payments-admin-table th:nth-child(9),.payments-admin-table td:nth-child(9){min-width:155px!important;width:155px!important}
.payments-admin-table .payment-reference-text{min-width:0!important;width:300px!important;max-width:300px!important;white-space:normal!important;overflow-wrap:break-word!important;word-break:normal!important}
.payments-admin-table .doc-upload-cell{min-width:0!important;width:auto!important;max-width:none!important}
.payments-admin-table .doc-compact-box{display:inline-flex!important;width:auto!important;max-width:none!important;gap:6px!important;align-items:center!important;flex-wrap:nowrap!important;white-space:nowrap!important}
.payments-admin-table .doc-compact-status{display:inline-flex!important;align-items:center!important;gap:5px!important;min-width:0!important;flex:0 0 auto!important}
.payments-admin-table .chip{padding:6px 9px!important;border-radius:10px!important;font-size:11px!important;white-space:nowrap!important}
.payments-admin-table .muted.mini{font-size:12px!important;white-space:nowrap!important}
.payments-admin-table .btn.tiny{font-size:10.5px!important;padding:4px 7px!important;min-height:28px!important}
.payments-admin-table .table-actions{white-space:nowrap!important;width:auto!important;min-width:0!important}

/* Plans/actions: compact icon actions and stable widths. */
.plans-admin-table{width:max-content!important;min-width:1200px!important;table-layout:auto!important}
.plans-admin-table th:nth-child(10),.plans-admin-table td:nth-child(10){min-width:130px!important;width:130px!important;white-space:nowrap!important}
.clients-admin-table th:last-child,.clients-admin-table td:last-child{min-width:140px!important;width:140px!important;white-space:nowrap!important}
.costs-admin-table th:last-child,.costs-admin-table td:last-child,.annual-costs-table th:last-child,.annual-costs-table td:last-child,.documents-admin-table th:last-child,.documents-admin-table td:last-child{min-width:105px!important;width:105px!important;white-space:nowrap!important}
.data-table td.actions,.data-table td.table-actions,.data-table td.compact-actions{white-space:nowrap!important}
.data-table td.actions > a,.data-table td.actions > form,.data-table td.table-actions > a,.data-table td.table-actions > form,.data-table td.compact-actions > a,.data-table td.compact-actions > form{display:inline-flex!important;vertical-align:middle!important;flex:0 0 auto!important}

@media (max-width:700px){
    .payments-admin-table{min-width:1180px!important}
    .plans-admin-table{min-width:1200px!important}
    .btn.icon-btn{width:32px!important;height:32px!important;min-width:32px!important;min-height:32px!important}
}

/* v1.0.37 - dashboard analytics and homologous comparisons */
.dashboard-analytics{margin-top:6px;overflow:hidden}
.analytics-cards{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:20px}
.analytics-mini-card{min-width:0;border:1px solid var(--line);border-radius:18px;background:#fff;padding:16px 17px;display:grid;gap:6px;box-shadow:0 12px 28px rgba(15,23,42,.035)}
.analytics-mini-card span{color:var(--muted);font-size:11px;font-weight:950;text-transform:uppercase;letter-spacing:.075em;line-height:1.2}
.analytics-mini-card strong{font-size:clamp(21px,2.4vw,28px);line-height:1.05;letter-spacing:-.04em;white-space:normal;overflow-wrap:anywhere}
.analytics-mini-card small{color:var(--muted);font-size:12px;font-weight:750;line-height:1.25}
.analytics-mini-card em{font-style:normal;font-size:12px;font-weight:950;line-height:1.25}
.analytics-mini-card.is-good em{color:var(--success)}
.analytics-mini-card.is-bad em{color:var(--danger)}
.analytics-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.chart-card{min-width:0;border:1px solid var(--line);border-radius:20px;background:linear-gradient(180deg,#fff,#fbfcff);padding:18px;box-shadow:0 14px 35px rgba(15,23,42,.04)}
.chart-head{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;margin-bottom:10px}
.chart-head h3{margin:0;font-size:17px;letter-spacing:-.025em;line-height:1.2}
.chart-head p{font-size:12px;margin:0;white-space:nowrap}
.chart-card canvas{display:block;width:100%;height:260px;max-width:100%;cursor:default}
.chart-empty{padding:38px 12px;text-align:center;border:1px dashed var(--line);border-radius:16px;background:#fff;margin:8px 0 0!important}
@media(max-width:1150px){.analytics-cards{grid-template-columns:repeat(2,minmax(0,1fr))}.analytics-grid{grid-template-columns:1fr}}
@media(max-width:620px){.analytics-cards{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.analytics-mini-card{padding:14px}.chart-card{padding:14px}.chart-head{display:block}.chart-head p{margin-top:4px;white-space:normal}.chart-card canvas{height:240px}.dashboard-analytics .section-title p{font-size:13px}}
@media(max-width:380px){.analytics-cards{grid-template-columns:1fr}}

/* v1.0.39 - remember login, permissions and pagination */
.sidebar-collapse-toggle{
    display:inline-grid!important;
    place-items:center!important;
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    border-radius:16px!important;
    border:1px solid rgba(255,255,255,.12)!important;
    background:linear-gradient(135deg,rgba(255,255,255,.14),rgba(255,255,255,.06))!important;
    color:#fff!important;
    cursor:pointer!important;
    box-shadow:inset 0 1px 0 rgba(255,255,255,.10),0 10px 22px rgba(0,0,0,.16)!important;
    transition:transform .16s ease,background .16s ease,border-color .16s ease,box-shadow .16s ease!important;
}
.sidebar-collapse-toggle:hover{
    transform:translateY(-1px)!important;
    background:linear-gradient(135deg,rgba(197,157,95,.35),rgba(255,255,255,.08))!important;
    border-color:rgba(197,157,95,.45)!important;
    box-shadow:inset 0 1px 0 rgba(255,255,255,.12),0 14px 30px rgba(0,0,0,.22)!important;
}
.sidebar-collapse-toggle .collapse-icon,
.sidebar-collapse-toggle .collapse-icon svg{
    display:block!important;
    width:22px!important;
    height:22px!important;
    transition:transform .18s ease!important;
}
.sidebar-collapse-toggle .collapse-icon svg path{
    fill:none!important;
    stroke:currentColor!important;
    stroke-width:2.4!important;
    stroke-linecap:round!important;
    stroke-linejoin:round!important;
}
body.sidebar-collapsed .sidebar-collapse-toggle .collapse-icon{transform:rotate(180deg)!important}
body.sidebar-collapsed .sidebar-collapse-toggle span{transform:rotate(180deg)!important}

.login-lock-table{min-width:940px!important}
.login-lock-table td:nth-child(2){min-width:230px!important}
.login-lock-table td:nth-child(4){min-width:190px!important}
.login-lock-table td:nth-child(6){min-width:260px!important;color:#475569!important}

.settings-form{gap:22px!important;max-width:1240px!important}
.settings-card{
    padding:24px!important;
    border-radius:26px!important;
    box-shadow:0 18px 45px rgba(15,23,42,.065)!important;
    align-items:start!important;
}
.settings-card .section-title{
    margin-bottom:6px!important;
    padding-bottom:14px!important;
}
.settings-card label{
    background:#fbfcff!important;
    border:1px solid #edf0f5!important;
    border-radius:18px!important;
    padding:12px!important;
    gap:9px!important;
}
.settings-card label.check{
    display:flex!important;
    align-items:flex-start!important;
    min-height:64px!important;
}
.settings-card label.check input{margin-top:3px!important}
.settings-card input,
.settings-card select,
.settings-card textarea{
    border-radius:14px!important;
    background:#fff!important;
    min-height:46px!important;
    padding:11px 13px!important;
}
.settings-card textarea{min-height:98px!important;line-height:1.45!important}
.settings-card .field-hint{font-size:11.5px!important;line-height:1.35!important;margin-top:-2px!important}
.settings-card .hint-box{
    background:linear-gradient(180deg,#fff,#fbfcff)!important;
    border-style:solid!important;
    border-color:#e8edf4!important;
}
.settings-form .sticky-actions{max-width:100%;margin-bottom:0!important}

@media (min-width:921px){
    .settings-card{grid-template-columns:repeat(2,minmax(260px,1fr))!important}
}
@media (max-width:760px){
    .settings-card{grid-template-columns:1fr!important;padding:18px!important;border-radius:22px!important}
    .settings-card label{padding:11px!important}
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    justify-content: flex-end;
    margin-top: 18px;
}

.permission-panel {
    border: 1px solid rgba(15, 23, 42, .08);
    border-radius: 18px;
    padding: 16px;
    background: rgba(248, 250, 252, .7);
}

.permission-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 10px 14px;
}

.remember-login {
    margin: 12px 0 16px;
}

/* v1.0.40 - Cliente 360 / cobranças inteligentes */
.page-actions{display:flex;gap:.65rem;flex-wrap:wrap;align-items:center;margin-top:.9rem}.client360-kpi-grid{grid-template-columns:repeat(4,minmax(0,1fr))}.client360-top-grid,.client360-bottom-grid,.client360-tables{align-items:start}.details-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.85rem;margin:0}.details-list div{background:#f8fafc;border:1px solid #e5e7eb;border-radius:14px;padding:.85rem}.details-list dt{font-size:.74rem;text-transform:uppercase;letter-spacing:.07em;color:#64748b;font-weight:800;margin-bottom:.25rem}.details-list dd{margin:0;color:#111827;font-weight:650;word-break:break-word}.soft-note{margin-top:1rem;padding:1rem;border-radius:14px;background:#fffbeb;border:1px solid #fde68a;color:#713f12}.mini-list{display:flex;flex-direction:column;gap:.35rem;margin-top:1rem;padding:.9rem;border-radius:14px;background:#f8fafc;border:1px solid #e5e7eb}.client360-billing-card .filter-grid{margin-bottom:.9rem}.smart-billing-form textarea{width:100%;resize:vertical}.timeline{position:relative;display:flex;flex-direction:column;gap:.8rem}.timeline-item{position:relative;display:grid;grid-template-columns:18px 1fr;gap:.75rem;padding:.75rem;border:1px solid #e5e7eb;background:#fff;border-radius:14px}.timeline-dot{width:11px;height:11px;border-radius:999px;background:#2563eb;margin-top:.25rem;box-shadow:0 0 0 4px #dbeafe}.timeline-item strong{display:block;color:#111827}.timeline-item small{display:block;color:#64748b;margin-top:.15rem}.timeline-item.sent .timeline-dot{background:#16a34a;box-shadow:0 0 0 4px #dcfce7}.timeline-item.failed .timeline-dot{background:#dc2626;box-shadow:0 0 0 4px #fee2e2}.empty-state.compact{padding:1rem;margin:0}.block{display:block}.mini{font-size:.78rem}.client-show-head .page-actions .btn{white-space:nowrap}@media (max-width:1100px){.client360-kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.details-list{grid-template-columns:1fr}}@media (max-width:700px){.client360-kpi-grid{grid-template-columns:1fr}.page-actions{width:100%}.page-actions .btn{flex:1}.timeline-item{grid-template-columns:14px 1fr}.details-list div{padding:.75rem}}

/* v1.0.41 - Cliente 360 professional polish, compact tables and safer vertical density */
.client360-page{
    display:grid!important;
    gap:22px!important;
    max-width:1540px!important;
    margin:0 auto!important;
}
.client360-page .client360-hero,
.client360-page .client360-card,
.client360-page .client360-kpi-card{
    border:1px solid rgba(148,163,184,.22)!important;
    box-shadow:0 18px 44px rgba(15,23,42,.055)!important;
}
.client360-hero{
    display:flex!important;
    justify-content:space-between!important;
    align-items:flex-start!important;
    gap:22px!important;
    padding:28px!important;
    border-radius:30px!important;
    background:
        radial-gradient(circle at 5% 0%,rgba(197,157,95,.16),transparent 30%),
        linear-gradient(180deg,#fff,#fbfcff)!important;
    overflow:hidden!important;
}
.client360-hero-main{min-width:0!important;max-width:980px!important}
.client360-hero h1{
    margin:8px 0 10px!important;
    font-size:clamp(30px,4.2vw,48px)!important;
    line-height:1!important;
    letter-spacing:-.055em!important;
}
.client360-hero p{
    max-width:860px!important;
    margin:0!important;
    color:#64748b!important;
    font-size:15px!important;
    line-height:1.55!important;
}
.client360-actions{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-end!important;
    gap:10px!important;
    flex:0 0 auto!important;
    flex-wrap:wrap!important;
}
.client360-meta-row{
    display:flex!important;
    flex-wrap:wrap!important;
    gap:10px!important;
    margin-top:18px!important;
}
.client360-pill{
    display:inline-flex!important;
    align-items:center!important;
    gap:8px!important;
    min-height:38px!important;
    padding:7px 11px!important;
    border-radius:999px!important;
    background:rgba(255,255,255,.72)!important;
    border:1px solid #e8edf4!important;
    color:#334155!important;
    font-size:12px!important;
    font-weight:850!important;
    max-width:100%!important;
}
.client360-pill strong{
    color:#64748b!important;
    font-size:10.5px!important;
    text-transform:uppercase!important;
    letter-spacing:.07em!important;
}
.client360-kpi-grid{
    display:grid!important;
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    gap:16px!important;
}
.client360-kpi-card{
    position:relative!important;
    overflow:hidden!important;
    border-radius:24px!important;
    background:linear-gradient(180deg,#fff,#fbfcff)!important;
    padding:20px 21px!important;
    min-height:132px!important;
}
.client360-kpi-card:after{
    content:""!important;
    position:absolute!important;
    right:-34px!important;
    top:-42px!important;
    width:110px!important;
    height:110px!important;
    border-radius:999px!important;
    background:linear-gradient(135deg,rgba(197,157,95,.18),rgba(197,157,95,0))!important;
}
.client360-kpi-card span{
    display:block!important;
    color:#64748b!important;
    font-size:11px!important;
    font-weight:950!important;
    letter-spacing:.08em!important;
    text-transform:uppercase!important;
    line-height:1.2!important;
}
.client360-kpi-card strong{
    display:block!important;
    margin:9px 0 6px!important;
    color:#0f172a!important;
    font-size:clamp(23px,3vw,34px)!important;
    letter-spacing:-.045em!important;
    line-height:1.05!important;
    overflow-wrap:anywhere!important;
}
.client360-kpi-card small{
    display:block!important;
    color:#64748b!important;
    font-size:12px!important;
    line-height:1.35!important;
    font-weight:750!important;
}
.client360-grid{
    display:grid!important;
    gap:20px!important;
    align-items:start!important;
}
.client360-grid-two{grid-template-columns:repeat(2,minmax(0,1fr))!important}
.client360-card{
    background:#fff!important;
    border-radius:28px!important;
    padding:22px!important;
    margin:0!important;
    min-width:0!important;
}
.client360-card-head{
    display:flex!important;
    align-items:flex-start!important;
    justify-content:space-between!important;
    gap:16px!important;
    padding-bottom:14px!important;
    margin-bottom:16px!important;
    border-bottom:1px solid #edf0f5!important;
}
.client360-card-head h2{
    margin:0 0 4px!important;
    font-size:clamp(20px,2vw,26px)!important;
    letter-spacing:-.035em!important;
    line-height:1.08!important;
}
.client360-card-head p{
    margin:0!important;
    color:#64748b!important;
    font-size:13px!important;
    line-height:1.45!important;
}
.client360-details-list{
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:10px!important;
    margin:0!important;
}
.client360-details-list div{
    min-width:0!important;
    padding:12px 13px!important;
    border-radius:16px!important;
    background:linear-gradient(180deg,#fbfcff,#f8fafc)!important;
    border:1px solid #edf0f5!important;
}
.client360-details-list dt{
    margin:0 0 5px!important;
    color:#64748b!important;
    font-size:10.5px!important;
    font-weight:950!important;
    letter-spacing:.08em!important;
    text-transform:uppercase!important;
}
.client360-details-list dd{
    margin:0!important;
    color:#0f172a!important;
    font-size:14px!important;
    font-weight:800!important;
    line-height:1.35!important;
    overflow-wrap:anywhere!important;
}
.client360-note,
.client360-mini-list{
    margin-top:14px!important;
    padding:14px!important;
    border-radius:18px!important;
    background:#fffbeb!important;
    border:1px solid #fde68a!important;
    color:#713f12!important;
    line-height:1.5!important;
}
.client360-mini-list{
    display:grid!important;
    gap:6px!important;
    background:#fbfcff!important;
    border-color:#edf0f5!important;
    color:#334155!important;
}
.client360-billing-card{
    padding:26px!important;
}
.client360-billing-head{
    align-items:center!important;
}
.client360-billing-summary{
    display:grid!important;
    gap:5px!important;
    justify-items:end!important;
    text-align:right!important;
    min-width:220px!important;
}
.client360-billing-summary small{
    color:#64748b!important;
    font-size:12px!important;
    font-weight:800!important;
    line-height:1.35!important;
}
.client360-billing-form{
    display:grid!important;
    gap:16px!important;
}
.client360-form-panels{
    display:grid!important;
    gap:14px!important;
}
.client360-form-panel{
    margin:0!important;
    padding:16px!important;
    border:1px solid #edf0f5!important;
    border-radius:22px!important;
    background:linear-gradient(180deg,#fff,#fbfcff)!important;
    min-width:0!important;
}
.client360-form-panel legend{
    padding:0 8px!important;
    color:#0f172a!important;
    font-size:13px!important;
    font-weight:950!important;
    letter-spacing:.04em!important;
    text-transform:uppercase!important;
}
.client360-field-grid{
    display:grid!important;
    gap:14px!important;
    align-items:start!important;
}
.client360-field-grid.four{grid-template-columns:repeat(4,minmax(0,1fr))!important}
.client360-field-grid label,
.client360-notes-field{
    gap:7px!important;
    color:#1e293b!important;
    font-size:13px!important;
    font-weight:900!important;
}
.client360-field-grid input,
.client360-field-grid select,
.client360-notes-field textarea{
    min-height:48px!important;
    padding:11px 13px!important;
    border-radius:15px!important;
    background:#fff!important;
    border-color:#dfe5ee!important;
    font-size:14px!important;
    font-weight:750!important;
}
.client360-field-grid small,
.client360-notes-field small{
    color:#64748b!important;
    font-size:11.5px!important;
    font-weight:700!important;
    line-height:1.35!important;
}
.client360-notes-field textarea{
    min-height:94px!important;
    line-height:1.45!important;
}
.client360-form-footer{
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:14px!important;
    padding:14px!important;
    border-radius:20px!important;
    background:#f8fafc!important;
    border:1px solid #edf0f5!important;
}
.client360-form-footer span{
    color:#64748b!important;
    font-size:12.5px!important;
    font-weight:750!important;
    line-height:1.4!important;
}
.client360-table-zone,
.client360-history-zone{align-items:start!important}
.client360-count{
    display:inline-flex!important;
    align-items:center!important;
    white-space:nowrap!important;
    min-height:30px!important;
    padding:5px 9px!important;
    border-radius:999px!important;
    background:#f1f5f9!important;
    color:#475569!important;
    font-size:11px!important;
    font-weight:950!important;
    text-transform:uppercase!important;
    letter-spacing:.045em!important;
}
.client360-table-wrap{
    max-height:430px!important;
    overflow:auto!important;
    border-radius:18px!important;
    background:#fff!important;
}
.client360-table{
    min-width:720px!important;
    table-layout:auto!important;
}
.client360-table th,
.client360-table td{
    padding:12px 13px!important;
    white-space:nowrap!important;
}
.client360-table td:first-child{
    max-width:290px!important;
    white-space:normal!important;
    overflow-wrap:anywhere!important;
}
.client360-card-foot{
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    gap:12px!important;
    margin-top:13px!important;
    padding-top:13px!important;
    border-top:1px solid #edf0f5!important;
}
.client360-card-foot span{
    color:#64748b!important;
    font-size:12px!important;
    font-weight:800!important;
}
.client360-scroll-panel{
    max-height:440px!important;
    overflow:auto!important;
    padding-right:4px!important;
}
.client360-scroll-panel::-webkit-scrollbar,
.client360-table-wrap::-webkit-scrollbar{width:9px!important;height:9px!important}
.client360-scroll-panel::-webkit-scrollbar-thumb,
.client360-table-wrap::-webkit-scrollbar-thumb{background:#cbd5e1!important;border-radius:999px!important}
.client360-scroll-panel::-webkit-scrollbar-track,
.client360-table-wrap::-webkit-scrollbar-track{background:#f8fafc!important;border-radius:999px!important}
.client360-page .timeline{
    gap:10px!important;
}
.client360-page .timeline-item{
    grid-template-columns:16px 1fr!important;
    gap:10px!important;
    padding:12px!important;
    border-radius:16px!important;
    border-color:#edf0f5!important;
    background:linear-gradient(180deg,#fff,#fbfcff)!important;
}
.client360-page .timeline-dot{
    width:10px!important;
    height:10px!important;
    margin-top:4px!important;
}
.client360-page .timeline-item strong{
    font-size:13.5px!important;
    line-height:1.25!important;
}
.client360-page .timeline-item small{
    font-size:12px!important;
    line-height:1.35!important;
}
.client360-page .empty-state.compact{
    padding:18px!important;
    border-radius:16px!important;
    background:#fbfcff!important;
    border:1px dashed #d8dee9!important;
}
@media (max-width:1280px){
    .client360-kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
    .client360-field-grid.four{grid-template-columns:repeat(2,minmax(0,1fr))!important}
}
@media (max-width:1060px){
    .client360-grid-two{grid-template-columns:1fr!important}
    .client360-hero{display:grid!important}
    .client360-actions{justify-content:flex-start!important}
    .client360-billing-summary{justify-items:start!important;text-align:left!important;min-width:0!important}
}
@media (max-width:720px){
    .client360-page{gap:16px!important}
    .client360-hero,
    .client360-card,
    .client360-billing-card{padding:18px!important;border-radius:24px!important}
    .client360-kpi-grid{grid-template-columns:1fr!important;gap:12px!important}
    .client360-details-list{grid-template-columns:1fr!important}
    .client360-field-grid.four{grid-template-columns:1fr!important}
    .client360-card-head,
    .client360-billing-head,
    .client360-form-footer,
    .client360-card-foot{display:grid!important;justify-items:start!important}
    .client360-actions,
    .client360-actions .btn,
    .client360-form-footer .btn{width:100%!important}
    .client360-table{min-width:640px!important}
    .client360-table-wrap,
    .client360-scroll-panel{max-height:360px!important}
}

/* v1.0.42 - Cliente 360 hotfix: cache bust + hard layout override */
.client360-page{
    width:100%!important;
    max-width:1480px!important;
    margin:0 auto!important;
    padding-bottom:22px!important;
}
.client360-page *{box-sizing:border-box!important}
.client360-page .client360-hero{
    display:grid!important;
    grid-template-columns:minmax(0,1fr) auto!important;
    align-items:start!important;
    gap:22px!important;
}
.client360-page .client360-hero-main{display:grid!important;gap:0!important;min-width:0!important}
.client360-page .client360-meta-row{display:flex!important;align-items:center!important;flex-wrap:wrap!important;gap:10px!important}
.client360-page .client360-pill{display:inline-flex!important;align-items:center!important;gap:8px!important;line-height:1!important;white-space:normal!important}
.client360-page .client360-kpi-grid{display:grid!important}
.client360-page .client360-kpi-card{display:block!important}
.client360-page .client360-grid{display:grid!important}
.client360-page .client360-card{display:block!important}
.client360-page .client360-card-head{display:flex!important}
.client360-page .client360-details-list{display:grid!important}
.client360-page .client360-details-list>div{display:grid!important;gap:2px!important}
.client360-page .client360-details-list dt,.client360-page .client360-details-list dd{display:block!important}
.client360-page .client360-form-panel{display:block!important}
.client360-page .client360-field-grid{display:grid!important}
.client360-page .client360-field-grid label,
.client360-page .client360-notes-field{
    display:grid!important;
    grid-template-columns:1fr!important;
    align-content:start!important;
    min-width:0!important;
}
.client360-page .client360-field-grid input,
.client360-page .client360-field-grid select,
.client360-page .client360-notes-field textarea{display:block!important;width:100%!important;max-width:100%!important}
.client360-page .client360-table-wrap.table-wrap{
    border:1px solid #edf0f5!important;
    background:#fff!important;
    overflow:auto!important;
    -webkit-overflow-scrolling:touch!important;
}
.client360-page table.client360-table.data-table{
    width:100%!important;
    border-collapse:separate!important;
    border-spacing:0!important;
}
.client360-page .client360-table th,
.client360-page .client360-table td{vertical-align:middle!important}
.client360-page .client360-card-foot .btn{white-space:nowrap!important}
.client360-page .client360-scroll-panel{display:grid!important;align-content:start!important}
.client360-page .timeline-item{display:grid!important}

@media (max-width:700px){
    .client360-page .client360-hero{grid-template-columns:1fr!important}
    .client360-page .client360-actions{display:grid!important;grid-template-columns:1fr!important}
    .client360-page .client360-actions .btn{width:100%!important}
    .client360-page .client360-card-head{display:grid!important;grid-template-columns:1fr!important;gap:10px!important}
    .client360-page .client360-table-wrap.table-wrap{
        border:1px solid #edf0f5!important;
        border-radius:18px!important;
        background:#fff!important;
        overflow:auto!important;
    }
    .client360-page table.data-table.client360-table{display:table!important;min-width:680px!important}
    .client360-page .data-table.client360-table thead{display:table-header-group!important}
    .client360-page .data-table.client360-table tbody{display:table-row-group!important}
    .client360-page .data-table.client360-table tr{display:table-row!important;background:transparent!important;border:0!important;border-radius:0!important;margin:0!important;box-shadow:none!important;overflow:visible!important}
    .client360-page .data-table.client360-table th,
    .client360-page .data-table.client360-table td{display:table-cell!important;text-align:left!important;border-bottom:1px solid #edf0f5!important;padding:12px 13px!important}
    .client360-page .data-table.client360-table td::before{content:none!important;display:none!important}
    .client360-page .client360-card-foot{display:grid!important;grid-template-columns:1fr!important;align-items:start!important}
    .client360-page .client360-card-foot .btn{width:100%!important}
}

/* v1.0.43 - Smart billing calculation UX */
.client360-field-grid.three{grid-template-columns:repeat(3,minmax(0,1fr))!important}
.client360-inline-actions{
    display:flex!important;
    align-items:center!important;
    flex-wrap:wrap!important;
    gap:10px 14px!important;
    margin-top:12px!important;
    padding:12px 13px!important;
    border-radius:16px!important;
    background:#f8fafc!important;
    border:1px dashed #d8dee9!important;
}
.client360-inline-actions span{
    color:#64748b!important;
    font-size:12px!important;
    font-weight:800!important;
    line-height:1.4!important;
}
@media (max-width:1280px){.client360-field-grid.three{grid-template-columns:repeat(2,minmax(0,1fr))!important}}
@media (max-width:720px){.client360-field-grid.three{grid-template-columns:1fr!important}.client360-inline-actions{display:grid!important}.client360-inline-actions .btn{width:100%!important}}

/* v1.0.44 - dashboard default period and year filter polish */
.dashboard-filter .filter-head{align-items:center!important}
.filter-badges{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex-wrap:wrap}
.filter-period{display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;border:1px solid #dbe7f5;background:#f8fbff;color:#334155;border-radius:999px;padding:7px 10px;font-size:12px;font-weight:950}
.dashboard-filter-grid{grid-template-columns:1.35fr 1fr .85fr .95fr .95fr .95fr!important}
.dashboard-kpi-title{margin:4px 0 14px!important}
.dashboard-kpi-title h2{font-size:20px!important;letter-spacing:-.03em!important}
.dashboard-kpi-title p{margin-top:4px!important}
@media(max-width:1280px){.dashboard-filter-grid{grid-template-columns:repeat(3,minmax(0,1fr))!important}}
@media(max-width:760px){.filter-badges{justify-content:flex-start}.filter-period{white-space:normal}.dashboard-filter-grid{grid-template-columns:1fr!important}.dashboard-kpi-title{margin-top:0!important}}

/* v1.0.49 - histórico de custos anuais por plano */
.plan-current-cost-box{border:1px solid #e5e7eb;border-radius:15px;padding:13px 14px;background:#f8fafc;display:grid;gap:4px;align-self:end}.plan-current-cost-box span,.plan-cost-current-strip span{color:#64748b;font-size:12px;font-weight:900;text-transform:uppercase;letter-spacing:.06em}.plan-current-cost-box strong,.plan-cost-current-strip strong{font-size:20px;letter-spacing:-.03em}.plan-current-cost-box small{color:#64748b;font-weight:700;line-height:1.35}.plan-cost-history-card{border-color:#dbeafe;background:linear-gradient(180deg,#fff,#fbfdff)}.plan-cost-current-strip{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:18px}.plan-cost-current-strip>div{border:1px solid #e5e7eb;background:#fff;border-radius:16px;padding:14px;display:grid;gap:5px}.plan-cost-add-form{border:1px solid #e5e7eb;background:#f8fafc;border-radius:18px;padding:16px;margin-bottom:18px}.plan-cost-add-form .section-title{border-bottom:0;margin-bottom:12px;padding-bottom:0}.plan-cost-add-grid{grid-template-columns:1fr 1fr 1.4fr auto}.plan-cost-version-list{display:grid;gap:8px}.plan-cost-version-head,.plan-cost-version-row,.plan-cost-version-edit{display:grid;grid-template-columns:150px 160px 130px minmax(220px,1fr) auto;gap:10px;align-items:center}.plan-cost-version-head{padding:0 12px;color:#64748b;font-size:11px;font-weight:950;text-transform:uppercase;letter-spacing:.075em}.plan-cost-version-row{border:1px solid #e5e7eb;background:#fff;border-radius:16px;padding:10px}.plan-cost-version-edit{grid-column:1/-1}.plan-cost-delete-form{justify-self:end;margin-top:-44px;margin-right:4px}.plan-cost-actions{justify-content:flex-end}.readonly-date{min-height:42px;border:1px solid #e5e7eb;border-radius:13px;background:#f8fafc;padding:11px 12px;font-weight:850;color:#475569;display:flex;align-items:center}.sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}@media(max-width:1000px){.plan-cost-current-strip{grid-template-columns:1fr}.plan-cost-add-grid{grid-template-columns:1fr}.plan-cost-version-head{display:none}.plan-cost-version-row,.plan-cost-version-edit{grid-template-columns:1fr}.plan-cost-delete-form{justify-self:stretch;margin:8px 0 0}.plan-cost-delete-form .btn{width:100%}.plan-cost-actions .btn{width:100%}}
.plan-cost-version-row{grid-template-columns:minmax(0,1fr) auto!important}.plan-cost-version-edit{grid-column:auto!important}.plan-cost-delete-form{margin:0!important;align-self:center}.plan-cost-delete-form .btn{min-width:38px}@media(max-width:1000px){.plan-cost-version-row{grid-template-columns:1fr!important}.plan-cost-version-edit{grid-template-columns:1fr!important}}

/* v1.0.51 - Client 360 smart billing no-plan guard */
.client360-plan-required{display:grid!important;gap:10px!important}
.client360-plan-required p{margin:0!important;line-height:1.55!important;font-weight:700!important;color:#92400e!important}
.client360-plan-required .client360-inline-actions{margin-top:2px!important;background:rgba(255,255,255,.45)!important;border-color:#f6c765!important}

.plan-billing-card .plan-billing-summary {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .75rem 1rem;
    border-radius: 14px;
    background: rgba(15, 23, 42, .04);
    border: 1px solid rgba(15, 23, 42, .08);
}
.plan-billing-card .plan-billing-tools {
    display: flex;
    align-items: center;
    gap: .75rem;
    flex-wrap: wrap;
    padding-top: .25rem;
}
.plan-billing-card [data-billing-calculation-note] {
    color: var(--muted, #64748b);
    font-size: .9rem;
}

/* v1.0.56 - mobile payments without page horizontal overflow */
@media (max-width:700px){
    .admin-body .admin-main,
    .admin-body .page-head,
    .admin-body .filter-card,
    .admin-body .card{
        max-width:100%!important;
        overflow-x:hidden!important;
    }
    .payments-admin-table{
        display:block!important;
        width:100%!important;
        min-width:0!important;
        max-width:100%!important;
        table-layout:fixed!important;
    }
    .payments-admin-table thead{
        display:none!important;
    }
    .payments-admin-table tbody{
        display:block!important;
        width:100%!important;
    }
    .payments-admin-table tr{
        display:block!important;
        width:100%!important;
        max-width:100%!important;
        margin:0 0 14px!important;
        padding:12px 13px!important;
        border:1px solid var(--line)!important;
        border-radius:18px!important;
        background:#fff!important;
        box-shadow:0 10px 26px rgba(15,23,42,.045)!important;
        overflow:hidden!important;
    }
    .payments-admin-table td{
        display:grid!important;
        grid-template-columns:92px minmax(0,1fr)!important;
        gap:8px!important;
        width:100%!important;
        min-width:0!important;
        max-width:100%!important;
        padding:9px 0!important;
        border:0!important;
        border-bottom:1px solid var(--line)!important;
        text-align:left!important;
        white-space:normal!important;
        overflow-wrap:anywhere!important;
    }
    .payments-admin-table td:last-child{
        border-bottom:0!important;
    }
    .payments-admin-table td::before{
        content:attr(data-label)!important;
        display:block!important;
        color:var(--muted)!important;
        font-size:11px!important;
        font-weight:950!important;
        text-transform:uppercase!important;
        letter-spacing:.055em!important;
        line-height:1.25!important;
        padding-top:2px!important;
    }
    .payments-admin-table td.actions,
    .payments-admin-table td.table-actions,
    .payments-admin-table td.compact-actions{
        display:block!important;
        white-space:normal!important;
        min-width:0!important;
        width:100%!important;
        max-width:100%!important;
        padding-top:11px!important;
    }
    .payments-admin-table td.actions::before,
    .payments-admin-table td.table-actions::before,
    .payments-admin-table td.compact-actions::before{
        margin-bottom:8px!important;
    }
    .payments-admin-table td.actions > a,
    .payments-admin-table td.actions > form,
    .payments-admin-table td.table-actions > a,
    .payments-admin-table td.table-actions > form,
    .payments-admin-table td.compact-actions > a,
    .payments-admin-table td.compact-actions > form{
        display:inline-flex!important;
        margin:2px 4px 2px 0!important;
        vertical-align:middle!important;
    }
    .payments-admin-table .payment-reference-text{
        width:100%!important;
        min-width:0!important;
        max-width:100%!important;
        white-space:normal!important;
        overflow-wrap:anywhere!important;
    }
    .payments-admin-table .doc-upload-cell{
        width:100%!important;
        min-width:0!important;
        max-width:100%!important;
    }
    .payments-admin-table .doc-compact-box{
        display:flex!important;
        width:100%!important;
        max-width:100%!important;
        flex-wrap:wrap!important;
        white-space:normal!important;
        gap:7px!important;
    }
    .payments-admin-table .doc-compact-status,
    .payments-admin-table .doc-compact-upload{
        flex-wrap:wrap!important;
        white-space:normal!important;
        max-width:100%!important;
    }
    .payments-admin-table .chip,
    .payments-admin-table .muted.mini,
    .payments-admin-table .btn.tiny{
        white-space:normal!important;
    }
    .table-wrap:has(.payments-admin-table){
        overflow-x:hidden!important;
        overflow-y:visible!important;
        padding-bottom:0!important;
    }
}

/* v1.0.57 - pagamentos mobile sem overflow horizontal */
@media (max-width: 700px) {
    html,
    body,
    .admin-body,
    .admin-shell,
    .admin-main,
    .page-content,
    .content,
    .card {
        max-width: 100% !important;
        overflow-x: hidden !important;
    }

    .filter-card,
    .filter-grid,
    .filter-grid.seven,
    .filter-actions {
        min-width: 0 !important;
        max-width: 100% !important;
    }

    .filter-grid,
    .filter-grid.seven {
        display: grid !important;
        grid-template-columns: 1fr !important;
    }

    .filter-card input,
    .filter-card select,
    .filter-card button,
    .filter-card .btn {
        max-width: 100% !important;
    }

    .payments-table-wrap {
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: hidden !important;
        overflow-y: visible !important;
        cursor: auto !important;
    }

    .payments-admin-table {
        display: block !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
        border-collapse: separate !important;
        border-spacing: 0 !important;
    }

    .payments-admin-table thead {
        display: none !important;
    }

    .payments-admin-table tbody {
        display: block !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
    }

    .payments-admin-table tr {
        display: block !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
        margin: 0 0 14px 0 !important;
        padding: 12px 13px !important;
        border: 1px solid rgba(148, 163, 184, .28) !important;
        border-radius: 18px !important;
        background: #fff !important;
        box-shadow: 0 12px 28px rgba(15, 23, 42, .06) !important;
        overflow: hidden !important;
    }

    .payments-admin-table td,
    .payments-admin-table td.doc-upload-cell,
    .payments-admin-table td.actions,
    .payments-admin-table td.table-actions,
    .payments-admin-table td.compact-actions {
        display: grid !important;
        grid-template-columns: minmax(88px, 34%) minmax(0, 1fr) !important;
        gap: 8px !important;
        align-items: start !important;
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
        padding: 9px 0 !important;
        border: 0 !important;
        border-bottom: 1px solid rgba(226, 232, 240, .95) !important;
        white-space: normal !important;
        overflow-wrap: anywhere !important;
        word-break: normal !important;
    }

    .payments-admin-table td:last-child {
        border-bottom: 0 !important;
    }

    .payments-admin-table td::before {
        content: attr(data-label) !important;
        display: block !important;
        min-width: 0 !important;
        font-size: 11px !important;
        line-height: 1.25 !important;
        font-weight: 800 !important;
        color: #64748b !important;
        text-transform: uppercase !important;
        letter-spacing: .04em !important;
        white-space: normal !important;
    }

    .payments-admin-table td > * {
        min-width: 0 !important;
        max-width: 100% !important;
    }

    .payments-admin-table .payment-reference-text,
    .payments-admin-table .table-main-text,
    .payments-admin-table td:nth-child(2),
    .payments-admin-table td:nth-child(2) .payment-reference-text {
        min-width: 0 !important;
        width: auto !important;
        max-width: 100% !important;
        white-space: normal !important;
        overflow-wrap: anywhere !important;
        word-break: break-word !important;
    }

    .payments-admin-table .doc-compact-box,
    .payments-admin-table .doc-compact-status,
    .payments-admin-table .doc-compact-upload {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        display: flex !important;
        flex-wrap: wrap !important;
        align-items: center !important;
        gap: 6px !important;
        white-space: normal !important;
    }

    .payments-admin-table .chip,
    .payments-admin-table .badge,
    .payments-admin-table .muted,
    .payments-admin-table .btn,
    .payments-admin-table label.btn {
        max-width: 100% !important;
        white-space: normal !important;
        overflow-wrap: anywhere !important;
    }

    .payments-admin-table td.table-actions,
    .payments-admin-table td.actions,
    .payments-admin-table td.compact-actions {
        display: block !important;
        white-space: normal !important;
    }

    .payments-admin-table td.table-actions::before,
    .payments-admin-table td.actions::before,
    .payments-admin-table td.compact-actions::before {
        margin-bottom: 8px !important;
    }

    .payments-admin-table td.table-actions > a,
    .payments-admin-table td.table-actions > form,
    .payments-admin-table td.actions > a,
    .payments-admin-table td.actions > form,
    .payments-admin-table td.compact-actions > a,
    .payments-admin-table td.compact-actions > form {
        display: inline-flex !important;
        margin: 0 6px 6px 0 !important;
        vertical-align: middle !important;
    }

    .payments-admin-table .empty-state {
        display: block !important;
        text-align: center !important;
    }

    .payments-admin-table .empty-state::before {
        content: none !important;
    }
}


/* v1.0.58 - pagina de pagamentos sem overflow horizontal em tablet/mobile */
.payments-page,
.payments-page * {
    min-width: 0;
}
.payments-page {
    width: 100%;
    max-width: 100%;
    overflow-x: clip;
}
.payments-mobile-list {
    display: none;
}
.payments-page .payment-reference-text {
    overflow-wrap: anywhere;
    word-break: break-word;
}

@media (max-width: 1100px) {
    body.admin-body:has(.payments-page),
    body.admin-body:has(.payments-page) .admin-shell,
    body.admin-body:has(.payments-page) .admin-main {
        max-width: 100vw !important;
        overflow-x: hidden !important;
    }

    .payments-page .page-head,
    .payments-page .filter-card,
    .payments-page .payments-list-card,
    .payments-page .pagination {
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: hidden !important;
    }

    .payments-page .filter-grid,
    .payments-page .filter-grid.seven {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .payments-page .filter-grid label:first-child,
    .payments-page .filter-actions {
        grid-column: 1 / -1 !important;
    }

    .payments-page .payments-table-wrap,
    .payments-page .payments-admin-table {
        display: none !important;
        width: 0 !important;
        min-width: 0 !important;
        max-width: 0 !important;
        overflow: hidden !important;
    }

    .payments-page .payments-mobile-list {
        display: grid !important;
        gap: 14px !important;
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: hidden !important;
    }

    .payments-page .payment-mobile-card {
        width: 100% !important;
        max-width: 100% !important;
        overflow: hidden !important;
        border: 1px solid rgba(148, 163, 184, .28);
        border-radius: 18px;
        background: #fff;
        box-shadow: 0 12px 28px rgba(15, 23, 42, .06);
        padding: 14px;
    }

    .payments-page .payment-mobile-card-head {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
        padding-bottom: 10px;
        margin-bottom: 10px;
        border-bottom: 1px solid rgba(226, 232, 240, .95);
    }

    .payments-page .payment-mobile-card-head strong {
        overflow-wrap: anywhere;
        line-height: 1.25;
    }

    .payments-page .payment-mobile-fields {
        display: grid;
        gap: 0;
        margin: 0;
    }

    .payments-page .payment-mobile-fields > div {
        display: grid;
        grid-template-columns: minmax(92px, 34%) minmax(0, 1fr);
        gap: 9px;
        padding: 9px 0;
        border-bottom: 1px solid rgba(226, 232, 240, .95);
    }

    .payments-page .payment-mobile-fields dt {
        margin: 0;
        color: #64748b;
        font-size: 11px;
        line-height: 1.25;
        font-weight: 900;
        text-transform: uppercase;
        letter-spacing: .04em;
    }

    .payments-page .payment-mobile-fields dd {
        margin: 0;
        min-width: 0;
        max-width: 100%;
        overflow-wrap: anywhere;
    }

    .payments-page .doc-compact-box,
    .payments-page .doc-compact-status,
    .payments-page .doc-compact-upload {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 6px !important;
        align-items: center !important;
        width: 100% !important;
        max-width: 100% !important;
        white-space: normal !important;
    }

    .payments-page .doc-compact-box .btn,
    .payments-page .doc-compact-box .chip,
    .payments-page .doc-compact-box .badge,
    .payments-page .doc-compact-box .muted {
        max-width: 100% !important;
        white-space: normal !important;
        overflow-wrap: anywhere !important;
    }

    .payments-page .payment-mobile-actions {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 7px !important;
        padding-top: 12px;
    }

    .payments-page .payment-mobile-actions > a,
    .payments-page .payment-mobile-actions > form {
        margin: 0 !important;
        flex: 0 0 auto !important;
    }

    .payments-page .pagination {
        justify-content: center !important;
    }
}

@media (max-width: 560px) {
    .payments-page .filter-grid,
    .payments-page .filter-grid.seven {
        grid-template-columns: 1fr !important;
    }
    .payments-page .payment-mobile-card {
        padding: 12px;
        border-radius: 16px;
    }
    .payments-page .payment-mobile-fields > div {
        grid-template-columns: 1fr;
        gap: 4px;
    }
    .payments-page .payment-mobile-card-head {
        display: grid;
    }
}


/* v1.0.59 - payments page overflow hard fix + mobile/tablet card layout */
html.payments-admin-html,
html.payments-admin-html body.payments-admin-body {
    max-width: 100% !important;
    overflow-x: hidden !important;
}

body.payments-admin-body .payments-page,
body.payments-admin-body .payments-page * {
    box-sizing: border-box !important;
    min-width: 0 !important;
}

body.payments-admin-body .payments-page {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
}

@media (max-width: 1100px) {
    html.payments-admin-html,
    html.payments-admin-html body.payments-admin-body,
    body.payments-admin-body .admin-shell {
        width: 100% !important;
        max-width: 100vw !important;
        overflow-x: hidden !important;
    }

    body.payments-admin-body .admin-main {
        width: 100% !important;
        max-width: 100vw !important;
        min-width: 0 !important;
        overflow-x: hidden !important;
    }

    body.payments-admin-body .payments-page .page-head,
    body.payments-admin-body .payments-page .filter-card,
    body.payments-admin-body .payments-page .payments-list-card,
    body.payments-admin-body .payments-page .pagination {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        overflow-x: hidden !important;
    }

    body.payments-admin-body .payments-page .filter-grid,
    body.payments-admin-body .payments-page .filter-grid.seven {
        display: grid !important;
        grid-template-columns: 1fr !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        gap: 12px !important;
    }

    body.payments-admin-body .payments-page .filter-grid label,
    body.payments-admin-body .payments-page .filter-grid input,
    body.payments-admin-body .payments-page .filter-grid select,
    body.payments-admin-body .payments-page .filter-actions,
    body.payments-admin-body .payments-page .filter-actions .btn {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
    }

    body.payments-admin-body .payments-page .filter-actions {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px !important;
    }

    body.payments-admin-body .payments-page .payments-table-wrap,
    body.payments-admin-body .payments-page table.payments-admin-table {
        display: none !important;
        visibility: hidden !important;
        position: absolute !important;
        left: -99999px !important;
        width: 0 !important;
        max-width: 0 !important;
        min-width: 0 !important;
        height: 0 !important;
        overflow: hidden !important;
        pointer-events: none !important;
    }

    body.payments-admin-body .payments-page .payments-mobile-list {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 14px !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        overflow-x: hidden !important;
    }

    body.payments-admin-body .payments-page .payment-mobile-card {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        overflow: hidden !important;
        border: 1px solid rgba(148, 163, 184, .28) !important;
        border-radius: 18px !important;
        background: #fff !important;
        box-shadow: 0 12px 28px rgba(15, 23, 42, .06) !important;
        padding: 14px !important;
    }

    body.payments-admin-body .payments-page .payment-mobile-card-head,
    body.payments-admin-body .payments-page .payment-mobile-fields,
    body.payments-admin-body .payments-page .payment-mobile-fields > div,
    body.payments-admin-body .payments-page .payment-mobile-actions,
    body.payments-admin-body .payments-page .doc-compact-box,
    body.payments-admin-body .payments-page .doc-compact-status,
    body.payments-admin-body .payments-page .doc-compact-upload {
        max-width: 100% !important;
        min-width: 0 !important;
        overflow-x: hidden !important;
    }

    body.payments-admin-body .payments-page .payment-mobile-card-head {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) auto !important;
        gap: 10px !important;
        align-items: start !important;
        padding-bottom: 10px !important;
        margin-bottom: 10px !important;
        border-bottom: 1px solid rgba(226, 232, 240, .95) !important;
    }

    body.payments-admin-body .payments-page .payment-mobile-fields {
        display: grid !important;
        gap: 0 !important;
        margin: 0 !important;
    }

    body.payments-admin-body .payments-page .payment-mobile-fields > div {
        display: grid !important;
        grid-template-columns: minmax(86px, 32%) minmax(0, 1fr) !important;
        gap: 8px !important;
        padding: 9px 0 !important;
        border-bottom: 1px solid rgba(226, 232, 240, .95) !important;
    }

    body.payments-admin-body .payments-page .payment-mobile-fields dt,
    body.payments-admin-body .payments-page .payment-mobile-fields dd {
        min-width: 0 !important;
        max-width: 100% !important;
        overflow-wrap: anywhere !important;
        word-break: break-word !important;
    }

    body.payments-admin-body .payments-page .doc-compact-box,
    body.payments-admin-body .payments-page .doc-compact-status,
    body.payments-admin-body .payments-page .doc-compact-upload,
    body.payments-admin-body .payments-page .payment-mobile-actions {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 6px !important;
        white-space: normal !important;
    }
}

@media (min-width: 921px) and (max-width: 1100px) {
    body.payments-admin-body .admin-main {
        margin-left: var(--sidebar) !important;
        width: calc(100vw - var(--sidebar)) !important;
        max-width: calc(100vw - var(--sidebar)) !important;
    }
    body.sidebar-collapsed.payments-admin-body .admin-main {
        margin-left: 86px !important;
        width: calc(100vw - 86px) !important;
        max-width: calc(100vw - 86px) !important;
    }
}

@media (max-width: 560px) {
    body.payments-admin-body .payments-page .payment-mobile-card-head,
    body.payments-admin-body .payments-page .payment-mobile-fields > div {
        grid-template-columns: 1fr !important;
    }
}

/* v1.0.60 - pagamentos: tabela compacta com scroll interno sem overflow da pagina */
html.payments-admin-html,
html.payments-admin-html body.payments-admin-body{
    width:100%!important;
    max-width:100%!important;
    overflow-x:hidden!important;
}
body.payments-admin-body .admin-shell,
body.payments-admin-body .admin-main,
body.payments-admin-body .payments-page,
body.payments-admin-body .payments-page .card,
body.payments-admin-body .payments-page .filter-card,
body.payments-admin-body .payments-page .payments-list-card{
    min-width:0!important;
    max-width:100%!important;
    overflow-x:hidden!important;
    box-sizing:border-box!important;
}
body.payments-admin-body .payments-page .payments-mobile-list,
body.payments-admin-body .payments-page .payment-mobile-card{
    display:none!important;
}
body.payments-admin-body .payments-page .compact-payments-card{
    padding:18px!important;
    overflow:hidden!important;
}
body.payments-admin-body .payments-page .table-section-title{
    display:flex!important;
    align-items:flex-end!important;
    justify-content:space-between!important;
    gap:12px!important;
    flex-wrap:wrap!important;
    margin-bottom:10px!important;
}
body.payments-admin-body .payments-page .table-scroll-hint{
    display:inline-flex!important;
    align-items:center!important;
    border:1px solid #e5e7eb!important;
    border-radius:999px!important;
    padding:6px 10px!important;
    background:#f8fafc!important;
    color:#64748b!important;
    font-size:11px!important;
    font-weight:850!important;
    letter-spacing:.02em!important;
    white-space:normal!important;
}
body.payments-admin-body .payments-page .payments-table-wrap,
body.payments-admin-body .payments-page .payments-compact-wrap{
    display:block!important;
    position:relative!important;
    left:auto!important;
    visibility:visible!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    height:auto!important;
    max-height:min(68vh, 680px)!important;
    overflow:auto!important;
    overflow-x:auto!important;
    overflow-y:auto!important;
    border:1px solid #e5e7eb!important;
    border-radius:16px!important;
    background:#fff!important;
    -webkit-overflow-scrolling:touch!important;
    overscroll-behavior:contain!important;
    cursor:grab!important;
    scrollbar-gutter:stable!important;
    pointer-events:auto!important;
}
body.payments-admin-body .payments-page .payments-table-wrap:active,
body.payments-admin-body .payments-page .payments-table-wrap.is-dragging{
    cursor:grabbing!important;
}
body.payments-admin-body .payments-page table.payments-admin-table,
body.payments-admin-body .payments-page table.payments-compact-table{
    display:table!important;
    visibility:visible!important;
    position:static!important;
    table-layout:fixed!important;
    width:100%!important;
    min-width:980px!important;
    max-width:none!important;
    height:auto!important;
    border-collapse:separate!important;
    border-spacing:0!important;
    background:#fff!important;
    pointer-events:auto!important;
}
body.payments-admin-body .payments-page .payments-compact-table col.payment-col-client{width:285px!important;}
body.payments-admin-body .payments-page .payments-compact-table col.payment-col-value{width:120px!important;}
body.payments-admin-body .payments-page .payments-compact-table col.payment-col-state{width:135px!important;}
body.payments-admin-body .payments-page .payments-compact-table col.payment-col-date{width:110px!important;}
body.payments-admin-body .payments-page .payments-compact-table col.payment-col-doc{width:150px!important;}
body.payments-admin-body .payments-page .payments-compact-table col.payment-col-receipt{width:175px!important;}
body.payments-admin-body .payments-page .payments-compact-table col.payment-col-actions{width:160px!important;}
body.payments-admin-body .payments-page .payments-compact-table thead{
    display:table-header-group!important;
}
body.payments-admin-body .payments-page .payments-compact-table tbody{
    display:table-row-group!important;
}
body.payments-admin-body .payments-page .payments-compact-table tr{
    display:table-row!important;
    height:auto!important;
    cursor:pointer!important;
    background:#fff!important;
    box-shadow:none!important;
    border-radius:0!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
}
body.payments-admin-body .payments-page .payments-compact-table tbody tr:hover td{
    background:#f8fafc!important;
}
body.payments-admin-body .payments-page .payments-compact-table th,
body.payments-admin-body .payments-page .payments-compact-table td{
    display:table-cell!important;
    height:auto!important;
    min-height:0!important;
    padding:8px 10px!important;
    border:0!important;
    border-bottom:1px solid #edf0f5!important;
    vertical-align:middle!important;
    text-align:left!important;
    white-space:normal!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    line-height:1.22!important;
    background:inherit!important;
}
body.payments-admin-body .payments-page .payments-compact-table th{
    position:sticky!important;
    top:0!important;
    z-index:2!important;
    background:#f8fafc!important;
    color:#64748b!important;
    font-size:10px!important;
    font-weight:900!important;
    letter-spacing:.055em!important;
    text-transform:uppercase!important;
    padding-top:9px!important;
    padding-bottom:9px!important;
}
body.payments-admin-body .payments-page .payments-compact-table td::before{
    content:none!important;
    display:none!important;
}
body.payments-admin-body .payments-page .payment-client-ref-cell strong{
    display:block!important;
    max-width:100%!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    white-space:nowrap!important;
    color:#111827!important;
    font-size:12px!important;
    line-height:1.2!important;
}
body.payments-admin-body .payments-page .payment-reference-text{
    display:block!important;
    min-width:0!important;
    max-width:100%!important;
    margin-top:3px!important;
    color:#64748b!important;
    font-size:11px!important;
    font-weight:750!important;
    line-height:1.2!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
}
body.payments-admin-body .payments-page .payment-value-cell strong{
    white-space:nowrap!important;
    font-size:13px!important;
}
body.payments-admin-body .payments-page .payment-status-cell{
    white-space:normal!important;
}
body.payments-admin-body .payments-page .payment-status-cell .payment-type-text{
    display:block!important;
    margin-bottom:4px!important;
    color:#64748b!important;
    font-size:10.5px!important;
    font-weight:850!important;
}
body.payments-admin-body .payments-page .payments-compact-table .badge{
    padding:4px 7px!important;
    font-size:10px!important;
    line-height:1!important;
    white-space:nowrap!important;
}
body.payments-admin-body .payments-page .payments-compact-table .doc-upload-cell{
    min-width:0!important;
    width:auto!important;
    max-width:none!important;
    overflow:visible!important;
}
body.payments-admin-body .payments-page .payments-compact-table .doc-compact-box{
    display:flex!important;
    align-items:center!important;
    gap:5px!important;
    flex-wrap:nowrap!important;
    white-space:nowrap!important;
    min-width:0!important;
    max-width:100%!important;
    overflow:hidden!important;
}
body.payments-admin-body .payments-page .payments-compact-table .doc-compact-status,
body.payments-admin-body .payments-page .payments-compact-table .doc-compact-upload{
    display:inline-flex!important;
    align-items:center!important;
    gap:4px!important;
    flex:0 1 auto!important;
    min-width:0!important;
    max-width:100%!important;
    margin:0!important;
    white-space:nowrap!important;
}
body.payments-admin-body .payments-page .payments-compact-table .chip,
body.payments-admin-body .payments-page .payments-compact-table .muted.mini{
    min-width:0!important;
    max-width:86px!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    white-space:nowrap!important;
    font-size:10.5px!important;
}
body.payments-admin-body .payments-page .payments-compact-table .btn.tiny,
body.payments-admin-body .payments-page .payments-compact-table .btn.small{
    min-height:24px!important;
    height:24px!important;
    padding:4px 7px!important;
    border-radius:8px!important;
    font-size:10px!important;
    line-height:1!important;
}
body.payments-admin-body .payments-page .payments-compact-table .icon-btn{
    width:26px!important;
    min-width:26px!important;
    height:26px!important;
    padding:0!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
}
body.payments-admin-body .payments-page .payments-compact-table .payment-actions-cell,
body.payments-admin-body .payments-page .payments-compact-table td.actions,
body.payments-admin-body .payments-page .payments-compact-table td.table-actions,
body.payments-admin-body .payments-page .payments-compact-table td.compact-actions{
    display:table-cell!important;
    white-space:nowrap!important;
    width:auto!important;
    min-width:0!important;
    max-width:none!important;
    overflow:visible!important;
}
body.payments-admin-body .payments-page .payments-compact-table .payment-actions-cell > a,
body.payments-admin-body .payments-page .payments-compact-table .payment-actions-cell > form,
body.payments-admin-body .payments-page .payments-compact-table td.actions > a,
body.payments-admin-body .payments-page .payments-compact-table td.actions > form{
    display:inline-flex!important;
    margin:0 3px 0 0!important;
    vertical-align:middle!important;
}
body.payments-admin-body .payments-page .payments-compact-table .empty-state{
    text-align:center!important;
    padding:18px!important;
}
body.payments-admin-body .payments-page .payments-compact-wrap::-webkit-scrollbar{
    width:10px!important;
    height:10px!important;
}
body.payments-admin-body .payments-page .payments-compact-wrap::-webkit-scrollbar-thumb{
    background:#cbd5e1!important;
    border-radius:999px!important;
}
body.payments-admin-body .payments-page .payments-compact-wrap::-webkit-scrollbar-track{
    background:#f8fafc!important;
    border-radius:999px!important;
}

@media (max-width:1100px){
    body.payments-admin-body .payments-page .payments-list-card{
        padding:14px!important;
    }
    body.payments-admin-body .payments-page .payments-table-wrap,
    body.payments-admin-body .payments-page .payments-compact-wrap{
        max-height:62vh!important;
        overflow:auto!important;
        cursor:grab!important;
    }
    body.payments-admin-body .payments-page table.payments-admin-table,
    body.payments-admin-body .payments-page table.payments-compact-table{
        min-width:930px!important;
    }
    body.payments-admin-body .payments-page .filter-grid,
    body.payments-admin-body .payments-page .filter-grid.seven{
        grid-template-columns:repeat(2,minmax(0,1fr))!important;
    }
    body.payments-admin-body .payments-page .filter-grid label:first-child,
    body.payments-admin-body .payments-page .filter-actions{
        grid-column:1/-1!important;
    }
}
@media (max-width:650px){
    body.payments-admin-body .payments-page .filter-grid,
    body.payments-admin-body .payments-page .filter-grid.seven{
        grid-template-columns:1fr!important;
    }
    body.payments-admin-body .payments-page table.payments-admin-table,
    body.payments-admin-body .payments-page table.payments-compact-table{
        min-width:880px!important;
    }
    body.payments-admin-body .payments-page .table-scroll-hint{
        width:100%!important;
        justify-content:center!important;
    }
}


/* v1.0.68 - form/input polish and smart-renewal table fixes */
.form-grid{align-items:start!important}
.form-grid>label,.form-grid>.plan-current-cost-box,.form-grid>.hint-box,.smart-billing-form label,.filter-grid>label{min-width:0!important;align-self:start!important}
.form-grid>label,.smart-billing-form label,.filter-card label{line-height:1.25!important}
.form-grid input,.form-grid select,.filter-card input,.filter-card select,.smart-billing-form input,.smart-billing-form select,.settings-card input,.settings-card select{height:52px!important;min-height:52px!important;padding:0 16px!important;line-height:1.2!important;display:block!important}
.form-grid textarea,.smart-billing-form textarea,.settings-card textarea{min-height:116px!important;padding:14px 16px!important;line-height:1.45!important;display:block!important}
.form-grid input[type="date"],.smart-billing-form input[type="date"],.filter-card input[type="date"]{line-height:52px!important}
.form-grid .field-hint,.smart-billing-form .field-hint,.filter-card small{margin-top:2px!important;min-height:0!important}
.plan-current-cost-box{align-self:start!important;min-height:92px!important;padding:16px!important;border-radius:17px!important}
.plan-billing-card .plan-billing-summary{display:flex!important;align-items:center!important;gap:12px!important;min-width:0!important;overflow:hidden!important}
.plan-billing-card .plan-billing-summary small{min-width:0!important;overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important}
.plan-billing-card .form-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;align-items:start!important}
.plans-admin-table td[data-label="Renovação"] span{font-weight:850!important;white-space:nowrap!important}
.plans-admin-table td[data-label="Renovação"] small{font-size:11px!important;line-height:1.3!important;white-space:normal!important}
.extra-row{align-items:start!important}
.extra-row input{height:48px!important;min-height:48px!important;padding:0 14px!important}
@media(max-width:920px){.form-grid,.plan-billing-card .form-grid{grid-template-columns:1fr!important}.plan-billing-card .plan-billing-summary{align-items:flex-start!important;flex-direction:column!important}.plan-billing-card .plan-billing-summary small{white-space:normal!important}.form-grid input,.form-grid select,.filter-card input,.filter-card select,.smart-billing-form input,.smart-billing-form select{height:50px!important;min-height:50px!important}}


/* v1.0.69 - polishing: payments spacing/buttons, mobile bottom nav, date-filter defaults */
.payments-page .payments-head{
    margin-bottom:18px!important;
    padding-bottom:14px!important;
    border-bottom:1px solid rgba(226,232,240,.85)!important;
}
.payments-page .payments-head h1{margin-top:6px!important;margin-bottom:6px!important;}
.payments-page .payments-head p{max-width:780px!important;margin-bottom:0!important;}
.payments-page .filter-card{margin-bottom:18px!important;}
.payments-page .payments-list-card{padding-top:18px!important;}
.payments-page .table-section-title{margin-bottom:12px!important;align-items:flex-end!important;}
.payments-admin-table .doc-upload-cell{min-width:250px!important;}
.payments-admin-table .doc-compact-box{
    display:inline-flex!important;
    align-items:center!important;
    gap:8px!important;
    flex-wrap:nowrap!important;
    white-space:nowrap!important;
}
.payments-admin-table .doc-compact-status,
.payments-admin-table .doc-compact-upload{display:inline-flex!important;align-items:center!important;gap:7px!important;margin:0!important;}
.payments-admin-table .doc-compact-box .chip,
.payments-admin-table .doc-compact-box .btn,
.payments-admin-table .doc-compact-box .badge,
.payments-admin-table .doc-compact-box .muted{
    min-height:34px!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    line-height:1!important;
    margin:0!important;
}
.payments-admin-table .doc-compact-box .chip,
.payments-admin-table .doc-compact-box .btn.tiny,
.payments-admin-table .doc-compact-box .btn.ghost{padding:8px 10px!important;border-radius:11px!important;}
.payments-admin-table .inline-delete-doc{margin:0!important;display:inline-flex!important;}
.payments-admin-table .table-actions,
.payments-admin-table .compact-actions,
.payments-admin-table .payment-actions-cell{display:flex!important;align-items:center!important;gap:7px!important;flex-wrap:nowrap!important;}
.payments-admin-table .payment-actions-cell form{margin:0!important;display:inline-flex!important;}
.payments-admin-table .payment-actions-cell .btn{min-width:34px!important;min-height:34px!important;}
.payments-page .page-head.row .btn{margin-left:auto!important;white-space:nowrap!important;}
.mobile-bottom-nav{display:none;}
@media (max-width:760px){
    .admin-main{padding-bottom:96px!important;}
    .mobile-bottom-nav{
        position:fixed;left:10px;right:10px;bottom:10px;z-index:60;
        display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;
        padding:8px;border:1px solid rgba(226,232,240,.92);border-radius:22px;
        background:rgba(255,255,255,.94);box-shadow:0 18px 44px rgba(15,23,42,.18);backdrop-filter:blur(16px);
    }
    .mobile-bottom-nav a{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;min-height:52px;border-radius:16px;color:#64748b;font-size:10px;font-weight:900;}
    .mobile-bottom-nav a.active{background:#111827;color:#fff;}
    .mobile-bottom-nav .nav-icon{width:18px;height:18px;}
    .mobile-bottom-nav .nav-icon svg{width:18px;height:18px;stroke:currentColor;stroke-width:2;fill:none;stroke-linecap:round;stroke-linejoin:round;}
    .payments-page .payments-head{align-items:stretch!important;gap:12px!important;}
    .payments-page .payments-head .btn{width:100%!important;margin-left:0!important;}
}

/* v1.0.72 - Histórico da anuidade do cliente */
.plan-price-history-card{border-color:#bbf7d0;background:linear-gradient(180deg,#ffffff,#f7fef9)}
.plan-price-current-strip>div{border-color:#dcfce7;background:#fff}
.plan-price-add-form{background:#f7fef9;border-color:#dcfce7}
.plan-price-version-list .readonly-date{background:#f8fafc}
.smart-billing-form [data-billing-amount-source]{font-weight:800}
