/* =====================================================
   Plataforma Administrativa — Grupo Orthovida
   style.css
   ===================================================== */
:root {
    --c-primary:    #132238;
    --c-primary-lt: #203a5f;
    --c-accent:     #1e88e5;
    --c-accent-h:   #1565c0;
    --c-bg:         #eef3f8;
    --c-card:       #ffffff;
    --c-border:     #d9e3ef;
    --c-text:       #102033;
    --c-muted:      #5f738a;
    --c-success:    #0f9d7a;
    --c-warning:    #d48a12;
    --c-danger:     #d64545;
    --c-info:       #1778c8;
    --radius:       18px;
    --radius-sm:    12px;
    --shadow:       0 16px 40px rgba(16,32,51,.08);
    --shadow-soft:  0 8px 24px rgba(17,24,39,.06);
    --surface-tint: linear-gradient(180deg, rgba(255,255,255,.95), rgba(248,251,255,.98));
}
*,*::before,*::after{box-sizing:border-box;}
body{
    font-family:"Segoe UI","Trebuchet MS","Helvetica Neue",sans-serif;
    font-size:14px;
    background:
        radial-gradient(circle at top, rgba(30,136,229,.10), transparent 26%),
        linear-gradient(180deg, #f6f9fc 0%, #edf3f8 44%, #e7eef6 100%);
    color:var(--c-text);
    margin:0;
    padding:0;
}
a{color:var(--c-accent);text-decoration:none;}
a:hover{text-decoration:underline;}

/* ── Header ── */
.site-header{
    background:linear-gradient(135deg, #132238 0%, #1a3150 58%, #23426b 100%);
    color:#fff;
    padding:12px 24px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    min-height:68px;
    gap:12px 18px;
    flex-wrap:wrap;
    box-shadow:0 14px 30px rgba(8,15,29,.22);
    position:sticky;
    top:0;
    z-index:50;
    backdrop-filter:blur(12px);
}
.header-brand{display:flex;align-items:center;gap:10px;flex:0 1 auto;min-width:0;}
.header-brand img.brand-logo{height:38px;width:auto;filter:drop-shadow(0 3px 10px rgba(0,0,0,.18));}
.header-brand-text{display:flex;flex-direction:column;min-width:0;}
.header-brand .brand-name{font-size:15px;font-weight:800;letter-spacing:.3px;}
.header-brand .brand-sub{font-size:11px;color:#adc1da;}
.header-nav{
    display:flex;
    align-items:center;
    justify-content:flex-end;
    flex:1 1 720px;
    min-width:0;
    gap:10px;
}
.header-nav-links{
    display:flex;
    align-items:center;
    flex-wrap:wrap;
    gap:6px 4px;
    min-width:0;
    flex:1 1 auto;
    overflow:visible;
    padding:2px 0 4px;
}
.header-nav-link,
.header-menu-group summary{
    display:inline-flex;
    align-items:center;
    flex:0 0 auto;
    max-width:100%;
    white-space:nowrap;
}
.header-nav-link,
.header-menu-group summary{
    color:#d7e3f2;
    padding:9px 13px;
    border-radius:999px;
    font-size:13px;
    line-height:1.2;
    transition:background .15s,transform .15s,border-color .15s;
    border:1px solid transparent;
    cursor:pointer;
    list-style:none;
}
.header-menu-group summary::-webkit-details-marker{display:none;}
.header-nav-link:hover,.header-nav-link.active,
.header-menu-group:hover summary,
.header-menu-group.active summary,
.header-menu-group[open] summary{
    color:#fff;
    background:rgba(255,255,255,.12);
    border-color:rgba(255,255,255,.12);
    text-decoration:none;
    transform:translateY(-1px);
}
.header-menu-group{
    position:relative;
    flex:0 0 auto;
    z-index:81;
}
.header-submenu{
    position:absolute;
    top:calc(100% + 10px);
    left:0;
    min-width:240px;
    display:none;
    padding:10px;
    border-radius:18px;
    background:rgba(12,21,36,.96);
    border:1px solid rgba(255,255,255,.08);
    box-shadow:0 20px 40px rgba(3,8,18,.28);
    backdrop-filter:blur(16px);
    z-index:80;
}
.header-menu-group:hover .header-submenu,
.header-menu-group[open] .header-submenu{
    display:grid;
    gap:4px;
}
.header-submenu-link{
    display:flex;
    align-items:center;
    padding:10px 12px;
    border-radius:12px;
    font-size:12px;
    color:#a8b9cf;
    background:rgba(255,255,255,.04);
    border:1px solid transparent;
    transition:background .15s,transform .15s,border-color .15s,color .15s;
}
.header-submenu-link:hover,
.header-submenu-link.active{
    color:#fff;
    background:rgba(255,255,255,.12);
    border-color:rgba(255,255,255,.12);
    text-decoration:none;
    transform:translateX(2px);
}
.header-nav-user{
    display:flex;
    align-items:center;
    gap:8px;
    flex:0 0 auto;
}
.header-user-name{
    color:#b4c4d8;
    font-size:12px;
    padding:8px 10px;
    border-radius:999px;
    background:rgba(255,255,255,.08);
}
.header-logout{
    display:inline-flex;
    align-items:center;
    color:#ffe0e0;
    padding:8px 12px;
    border-radius:999px;
    border:1px solid rgba(255,139,139,.4);
    background:rgba(198,40,40,.2);
    font-size:12px;
    font-weight:700;
}
.header-logout:hover{
    color:#fff;
    text-decoration:none;
    background:rgba(198,40,40,.32);
    border-color:rgba(255,169,169,.52);
}
@media(max-width:1180px){
    .site-header{align-items:flex-start;}
    .header-nav{
        width:100%;
        flex-basis:100%;
        justify-content:flex-start;
        flex-direction:column;
        align-items:stretch;
        gap:8px;
    }
    .header-nav-user{justify-content:flex-end;}
    .header-nav-links{overflow:visible;}
}
@media(max-width:760px){
    .site-header{padding:12px 16px;}
    .header-brand{width:100%;}
    .header-nav{width:100%;flex-basis:100%;justify-content:flex-start;}
    .header-nav-user{width:100%;justify-content:space-between;}
    .header-nav-links{
        width:100%;
        overflow:visible;
        flex-direction:column;
        align-items:stretch;
    }
    .header-nav-link,
    .header-menu-group summary{
        justify-content:space-between;
        width:100%;
    }
    .header-menu-group{
        width:100%;
    }
    .header-submenu{
        position:static;
        min-width:0;
        margin-top:6px;
        box-shadow:none;
        border-radius:14px;
        background:rgba(255,255,255,.08);
    }
}

/* ── Main layout ── */
.site-main{max-width:1440px;margin:30px auto;padding:0 22px 28px;}
.page-grid{display:grid;grid-template-columns:minmax(0,2fr) minmax(320px,1fr);gap:22px;}
.page-grid.full{grid-template-columns:1fr;}
@media(max-width:960px){.page-grid{grid-template-columns:1fr;}}

/* ── Cards ── */
.card{
    background:var(--surface-tint);
    border-radius:var(--radius);
    padding:22px 24px;
    box-shadow:var(--shadow);
    margin-bottom:22px;
    border:1px solid rgba(217,227,239,.9);
}
.card-title{
    font-size:17px;
    font-weight:800;
    margin:0 0 16px;
    padding-bottom:12px;
    border-bottom:1px solid rgba(217,227,239,.95);
    letter-spacing:.1px;
}
.card-subtitle{color:var(--c-muted);font-size:12px;margin-top:-10px;margin-bottom:14px;}

/* ── Form elements ── */
label{display:block;font-weight:600;margin-top:14px;font-size:13px;}
label .opt{font-weight:400;color:var(--c-muted);}
input[type=text],input[type=email],input[type=password],input[type=number],input[type=file],select,textarea{
    width:100%;padding:10px 12px;border:1px solid var(--c-border);border-radius:12px;
    margin-top:5px;font-size:13px;font-family:inherit;background:#fff;
    transition:border-color .15s, box-shadow .15s, background .15s;}
input:focus,select:focus,textarea:focus{outline:none;border-color:rgba(30,136,229,.5);box-shadow:0 0 0 4px rgba(30,136,229,.12);background:#fbfdff;}
textarea{min-height:100px;resize:vertical;}
select{cursor:pointer;}
.grid-2{display:grid;grid-template-columns:1fr 1fr;gap:14px;}
.grid-3{display:grid;grid-template-columns:1fr 1fr 1fr;gap:14px;}
.grid-4{display:grid;grid-template-columns:1fr 1fr 1fr 1fr;gap:14px;}
@media(max-width:700px){.grid-2,.grid-3,.grid-4{grid-template-columns:1fr;}}
.form-hint{font-size:11px;color:var(--c-muted);margin-top:4px;}
.hidden{display:none!important;}

/* ── Buttons ── */
.btn{display:inline-flex;align-items:center;gap:6px;padding:10px 16px;border:1px solid transparent;border-radius:999px;cursor:pointer;font-size:13px;font-weight:700;text-decoration:none;transition:background .18s,opacity .1s,transform .15s,box-shadow .18s,border-color .18s;white-space:nowrap;box-shadow:none;}
.btn:hover{opacity:1;text-decoration:none;transform:translateY(-1px);}
.btn-primary{background:linear-gradient(135deg, #1e88e5 0%, #1565c0 100%);color:#fff;box-shadow:0 10px 22px rgba(21,101,192,.22);}
.btn-primary:hover{background:linear-gradient(135deg, #1879cf 0%, #1459ab 100%);}
.btn-secondary{background:linear-gradient(135deg, #16283f 0%, #21395c 100%);color:#fff;box-shadow:0 10px 22px rgba(19,34,56,.16);}
.btn-secondary:hover{background:linear-gradient(135deg, #132238 0%, #1b3150 100%);}
.btn-success{background:linear-gradient(135deg, #16a085 0%, #0f8c73 100%);color:#fff;}
.btn-danger{background:linear-gradient(135deg, #e15252 0%, #cb3c3c 100%);color:#fff;}
.btn-warning{background:linear-gradient(135deg, #e39a26 0%, #c97a06 100%);color:#fff;}
.btn-info{background:linear-gradient(135deg, #1992c9 0%, #0d77b1 100%);color:#fff;}
.btn-ghost{background:rgba(255,255,255,.9);color:var(--c-primary);border:1px solid #c8d7e7;box-shadow:var(--shadow-soft);}
.btn-sm{padding:5px 11px;font-size:12px;}
.btn-lg{padding:12px 22px;font-size:15px;}
.btn-block{width:100%;justify-content:center;margin-top:16px;}

/* ── Alerts ── */
.alert{padding:12px 14px;border-radius:7px;margin-bottom:14px;font-size:13px;}
.alert-success{background:#ecfdf5;border:1px solid #a7f3d0;color:#065f46;}
.alert-danger {background:#fef2f2;border:1px solid #fca5a5;color:#7f1d1d;}
.alert-warning{background:#fffbeb;border:1px solid #fcd34d;color:#78350f;}
.alert-info   {background:#eff6ff;border:1px solid #93c5fd;color:#1e3a8a;}

/* ── Badges ── */
.badge{display:inline-block;padding:4px 10px;border-radius:999px;font-size:11px;font-weight:700;letter-spacing:.1px;}
.badge-juridico{background:#ddeefd;color:#1758bf;}
.badge-operacional{background:#daf6ea;color:#0e7856;}
.badge-signed{background:#fff2c7;color:#a36800;}

.finance-kanban{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:14px;overflow-x:auto;}
.finance-kanban-column{background:#f8fafc;border:1px solid #e2e8f0;border-radius:14px;padding:10px;min-width:280px;}
.finance-kanban-header{display:flex;justify-content:space-between;align-items:center;gap:8px;font-weight:700;color:#1e293b;margin-bottom:10px;padding-bottom:7px;border-bottom:2px solid #e2e8f0;font-size:13px;}
.finance-kanban-card{background:#fff;border:1px solid #e2e8f0;border-radius:12px;padding:10px;margin-bottom:8px;box-shadow:0 1px 2px rgba(15,23,42,.04);transition:transform .15s ease,box-shadow .15s ease;}
.finance-kanban-card:hover{transform:translateY(-1px);box-shadow:0 8px 18px rgba(15,23,42,.08);}
.finance-hero{background:linear-gradient(135deg,#132238 0%,#1c3a5e 54%,#28507d 100%);color:#fff;overflow:hidden;position:relative}
.finance-hero::after{content:"";position:absolute;inset:auto -40px -60px auto;width:220px;height:220px;background:radial-gradient(circle,rgba(255,255,255,.18),transparent 62%);pointer-events:none}
.finance-hero .card-title{color:#fff;border-bottom-color:rgba(255,255,255,.14)}
.finance-hero p,.finance-hero .form-hint{color:#d6e3f1}
.finance-hero label{color:#fff}
.finance-hero input,.finance-hero select,.finance-hero textarea{background:#f8fbff;color:#10233b;border-color:rgba(148,163,184,.42)}
.finance-hero input[readonly]{background:#eef4fb;color:#475569}
.finance-hero .panel-toolbar .btn,.finance-hero .btn-ghost{background:rgba(255,255,255,.12);color:#fff;border-color:rgba(255,255,255,.18)}
.finance-hero .btn-primary{background:#f8fbff;color:#1c3a5e}
.finance-hero .btn-ghost:hover,.finance-hero .btn-primary:hover{filter:brightness(.97)}
.collapsible-panel{overflow:hidden}
.collapsible-panel.is-collapsed > .collapsible-panel-body{display:none}
.panel-summary-row{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding:12px 18px 14px}
.collapsible-panel-body{padding:16px 18px 18px}
.panel-summary-copy{display:grid;gap:4px;min-width:0}
.panel-summary-copy .card-title{margin:0;padding-bottom:0;border-bottom:0}
.panel-summary-copy .text-small{margin:0}
.panel-summary-toggle{display:inline-flex;align-items:center;gap:10px;padding:10px 15px;border-radius:999px;background:rgba(255,255,255,.92);color:#15304f;font-weight:900;white-space:nowrap;border:1px solid rgba(255,255,255,.96);box-shadow:0 12px 26px rgba(15,23,42,.22);backdrop-filter:blur(10px);cursor:pointer}
.panel-summary-toggle .panel-summary-label{font-size:12px;font-weight:800;letter-spacing:.02em}
.panel-summary-toggle .panel-summary-plus{font-size:20px;line-height:1}
.badge-admin{background:#ede5ff;color:#6a32c9;}
.badge-gestor{background:#d8ebff;color:#1c4fa8;}
.badge-operador{background:#ebfaf1;color:#1f6f46;}
.badge-assinador{background:#fff1e2;color:#be5b16;}

/* ── Tables ── */
.table-wrap{overflow-x:auto;}
table.data-table{width:100%;border-collapse:collapse;}
table.data-table th{background:#f4f8fc;font-size:12px;font-weight:800;text-align:left;padding:10px 12px;border-bottom:1px solid var(--c-border);white-space:nowrap;color:#42566d;}
table.data-table td{padding:11px 12px;border-bottom:1px solid #e8eef5;font-size:13px;vertical-align:top;}
table.data-table tr:last-child td{border-bottom:0;}
table.data-table tr:hover td{background:#f8fbfe;}
.table-actions{display:flex;gap:6px;flex-wrap:wrap;}
.table-action-menu{display:flex;flex-direction:column;gap:7px;min-width:220px;}
.table-action-group{
    border:1px solid #dce6f2;
    border-radius:12px;
    background:#fff;
    padding:5px 7px;
}
.table-action-group[open]{
    background:#f7fbff;
    border-color:#cfe0f3;
}
.table-action-group > summary{
    list-style:none;
    cursor:pointer;
    display:inline-flex;
    align-items:center;
    gap:6px;
    font-size:11px;
    font-weight:700;
    color:#26476e;
    background:#eef5fc;
    border:1px solid #d7e5f4;
    border-radius:999px;
    padding:4px 9px;
    user-select:none;
}
.table-action-group > summary::-webkit-details-marker{display:none;}
.table-action-group > summary::before{content:"+";font-weight:800;line-height:1;}
.table-action-group[open] > summary::before{content:"−";}
.table-action-content{margin-top:8px;}
.table-action-content .stack-actions{margin-top:0;}
.table-action-content .quick-access{grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:8px;}
.table-action-content .quick-access .btn{min-height:32px;padding:5px 9px;font-size:11px;}
.mini-ico{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-width:20px;
    height:18px;
    padding:0 5px;
    border-radius:999px;
    border:1px solid #cfe0f2;
    background:#f3f8fe;
    color:#2b527d;
    font-size:10px;
    font-weight:800;
    line-height:1;
}
.btn .mini-ico{
    min-width:18px;
    height:16px;
    background:rgba(255,255,255,.55);
    border-color:rgba(255,255,255,.45);
    color:inherit;
}
.mini-ico-legend-card{margin-top:8px;}
.mini-ico-legend-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(190px,1fr));
    gap:8px 12px;
}
.mini-ico-legend-item{
    display:inline-flex;
    align-items:center;
    gap:8px;
    font-size:12px;
    color:#2f4764;
}

/* ── Stars & pins ── */
.star-btn{background:none;border:none;cursor:pointer;font-size:18px;padding:0;line-height:1;}
.star-btn.on{color:#d97706;}
.star-btn.off{color:#cbd5e1;}
.pin-btn{background:none;border:none;cursor:pointer;font-size:15px;padding:0;line-height:1;}
.pin-btn.on{color:var(--c-danger);}

/* ── Company info box ── */
.company-info{background:#f8fafc;border:1px solid var(--c-border);border-radius:7px;padding:10px 12px;font-size:12px;color:var(--c-muted);margin-top:6px;line-height:1.5;}

/* ── A4 Preview ── */
.preview-wrap{background:linear-gradient(180deg, #dfe7f1, #d7e0ec);padding:28px;border-radius:var(--radius);}
.preview-a4{max-width:210mm;min-height:200px;margin:0 auto;background:#fff;box-shadow:0 8px 30px rgba(0,0,0,.15);border:1px solid #d0d8e4;}

/* ── Auth pages ── */
.auth-wrap{max-width:440px;margin:80px auto;padding:0 20px;}
.auth-card{background:var(--c-card);border-radius:12px;padding:32px 36px;box-shadow:0 4px 24px rgba(0,0,0,.1);}
.auth-logo{text-align:center;margin-bottom:24px;}
.auth-logo .logo-name{font-size:18px;font-weight:700;color:var(--c-primary);}
.auth-logo .logo-sub{font-size:12px;color:var(--c-muted);}

/* ── Aceite items table ── */
.aceite-table{width:100%;border-collapse:collapse;margin-top:8px;}
.aceite-table th{background:var(--c-bg);font-size:12px;text-align:left;padding:6px 8px;border:1px solid var(--c-border);}
.aceite-table td{padding:5px 8px;border:1px solid var(--c-border);}
.aceite-table input{margin-top:0;padding:5px 7px;font-size:12px;}
.proposal-table{width:100%;border-collapse:collapse;margin-top:8px;}
.proposal-table th{background:var(--c-bg);font-size:12px;text-align:left;padding:6px 8px;border:1px solid var(--c-border);}
.proposal-table td{padding:5px 8px;border:1px solid var(--c-border);vertical-align:top;}
.proposal-table input,.proposal-table select{margin-top:0;padding:5px 7px;font-size:12px;}
.aceite-total{text-align:right;font-weight:700;font-size:14px;margin-top:8px;color:var(--c-primary);}
.btn-add-row{font-size:12px;padding:5px 10px;}

/* ── Filters/tabs ── */
.filter-bar{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin-bottom:12px;}
.filter-bar select,.filter-bar input{width:auto;margin-top:0;}
.filter-bar label{margin-top:0;font-weight:400;}
.panel-head{display:flex;justify-content:space-between;align-items:flex-start;gap:14px;flex-wrap:wrap;}
.panel-title{margin:0;border:0;padding:0;}
.panel-toolbar{display:flex;gap:8px;align-items:center;flex-wrap:wrap;}
.filter-bar.spaced{margin-top:14px;}
.filter-form{display:flex;gap:8px;flex-wrap:wrap;align-items:center;}
.filter-inline-input{min-width:260px;}
.filter-inline-input-sm{max-width:320px;}
.soft-card-list{display:grid;gap:10px;margin-top:16px;}
.quotation-hero{
    display:grid;
    grid-template-columns:minmax(0,1.6fr) minmax(280px,.9fr);
    gap:18px 22px;
    align-items:stretch;
    background:
        radial-gradient(circle at top right, rgba(30,136,229,.16), transparent 24%),
        linear-gradient(135deg, #ffffff 0%, #f7fbff 100%);
}
.quotation-hero-copy{display:flex;flex-direction:column;gap:10px;}
.quotation-kicker{
    display:inline-flex;
    align-self:flex-start;
    padding:4px 10px;
    border-radius:999px;
    background:rgba(30,136,229,.10);
    color:var(--c-accent-h);
    font-size:11px;
    font-weight:800;
    letter-spacing:.08em;
    text-transform:uppercase;
}
.quotation-title{
    margin:0;
    font-size:28px;
    line-height:1.1;
    letter-spacing:-.02em;
}
.quotation-lead{
    margin:0;
    max-width:72ch;
    color:var(--c-muted);
    font-size:14px;
    line-height:1.55;
}
.quotation-hero-meta{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
    margin-top:4px;
}
.quotation-chip{
    display:inline-flex;
    align-items:center;
    padding:7px 12px;
    border-radius:999px;
    background:#eef5fc;
    color:#1f3f64;
    border:1px solid #d6e5f4;
    font-size:12px;
    font-weight:700;
}
.quotation-hero-stats{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:12px;
}
.quotation-stat{
    display:flex;
    flex-direction:column;
    justify-content:space-between;
    min-height:108px;
    padding:16px 18px;
    border-radius:18px;
    background:linear-gradient(180deg,#0f172a 0%,#132238 100%);
    color:#fff;
    box-shadow:0 18px 30px rgba(18,34,56,.15);
}
.quotation-stat strong{
    font-size:28px;
    line-height:1;
    font-weight:900;
    letter-spacing:-.03em;
}
.quotation-stat span{
    margin-top:8px;
    color:#bfd0e8;
    font-size:12px;
}
.quotation-workbook{padding:20px 20px 22px;}
.quotation-workbook-head{margin-bottom:12px;}
.quotation-workbook-badges{display:flex;gap:8px;flex-wrap:wrap;align-items:center;}
.quotation-form{display:block;}
.quotation-meta-grid{display:grid;grid-template-columns:1.2fr .9fr 1.3fr .9fr;gap:14px;}
.quotation-meta-grid > div{min-width:0;}
.quotation-meta-grid .grid-2{grid-column:1/-1;}
.quotation-sheet-shell{padding-bottom:0;}
.sheet-ribbon{
    display:flex;
    flex-wrap:wrap;
    gap:12px;
    align-items:flex-start;
    padding:14px 16px;
    margin-bottom:14px;
    border:1px solid #dce7f2;
    border-radius:18px;
    background:linear-gradient(180deg,#fbfdff 0%,#f3f8fd 100%);
    box-shadow:var(--shadow-soft);
}
.sheet-ribbon-group{
    display:flex;
    flex-wrap:wrap;
    gap:8px;
    align-items:center;
    padding-right:16px;
    margin-right:2px;
    border-right:1px solid rgba(203,213,225,.75);
}
.sheet-ribbon-group:last-child{
    border-right:0;
    padding-right:0;
    margin-right:0;
    flex:1 1 280px;
}
.sheet-ribbon-label{
    font-size:11px;
    text-transform:uppercase;
    letter-spacing:.08em;
    color:#64748b;
    font-weight:800;
}
.sheet-ribbon-note{
    color:var(--c-muted);
    font-size:12px;
    line-height:1.45;
}
.quotation-sheet-wrap-strong{
    border-radius:18px;
    border:1px solid #dce7f2;
    box-shadow:0 14px 34px rgba(16,32,51,.08);
}
.quotation-sheet-shell{padding-bottom:18px;}
.quotation-sheet-head{align-items:flex-end;}
.quotation-sheet-wrap{overflow:auto;border:1px solid var(--c-border);border-radius:14px;background:#fff;box-shadow:inset 0 1px 0 rgba(255,255,255,.6);}
.quotation-sheet-table{width:100%;border-collapse:collapse;min-width:1100px;background:#fff;}
.quotation-sheet-table thead th{
    position:sticky;
    top:0;
    z-index:2;
    background:linear-gradient(180deg,#f6f9fd 0%,#ebf2f9 100%);
    color:#334155;
    font-size:12px;
    text-transform:uppercase;
    letter-spacing:.04em;
    padding:10px 12px;
    border-bottom:1px solid #dbe5ef;
    border-right:1px solid #e5edf5;
    white-space:nowrap;
}
.quotation-sheet-table tbody td{
    border-bottom:1px solid #edf3f8;
    border-right:1px solid #edf3f8;
    padding:0;
    vertical-align:top;
    background:#fff;
}
.quotation-sheet-table tbody tr:nth-child(even) td{background:#fbfdff;}
.quotation-sheet-table tbody tr:hover td{background:#f3f8fd;}
.quotation-sheet-table tbody tr.is-selected td{background:#eaf4ff;}
.quotation-sheet-table tbody tr.is-active td{box-shadow:inset 0 0 0 9999px rgba(30,136,229,.04);}
.quotation-sheet-table .qt-cell{
    width:100%;
    border:0;
    border-radius:0;
    margin:0;
    box-shadow:none;
    background:transparent;
    min-height:42px;
}
.quotation-sheet-table .qt-textarea{
    min-height:42px;
    resize:vertical;
}
.quotation-sheet-table td button{margin:6px;}
.quotation-sheet-table .sheet-cell-handle,
.quotation-sheet-table .sheet-cell-number{
    background:#f8fbfe;
    font-weight:700;
    text-align:center;
    color:#5b718a;
    vertical-align:middle;
}
.quotation-sheet-table .sheet-cell-handle{
    position:sticky;
    left:0;
    z-index:3;
    min-width:56px;
    box-shadow:1px 0 0 #edf3f8;
}
.quotation-sheet-table .sheet-cell-number{
    position:sticky;
    left:56px;
    z-index:2;
    min-width:74px;
    box-shadow:1px 0 0 #edf3f8;
}
.quotation-sheet-table thead .sheet-col-handle,
.quotation-sheet-table thead .sheet-col-number{
    position:sticky;
    top:0;
    z-index:5;
}
.quotation-sheet-table thead .sheet-col-handle{left:0;}
.quotation-sheet-table thead .sheet-col-number{left:56px;}
.quotation-sheet-table .sheet-cell-actions{
    background:#f8fbfe;
    white-space:nowrap;
}
.qt-row-toggle{
    width:28px;
    height:28px;
    padding:0;
    border-radius:999px;
    border:1px solid #d7e2ee;
    background:#fff;
    color:#7a8da4;
    font-weight:900;
    cursor:pointer;
    line-height:1;
    transition:transform .15s, background .15s, border-color .15s, color .15s;
}
.qt-row-toggle:hover{
    transform:translateY(-1px);
    border-color:#b8cce0;
}
.quotation-sheet-table .qt-row-toggle[aria-pressed="true"]{
    background:rgba(30,136,229,.12);
    border-color:rgba(30,136,229,.35);
    color:var(--c-accent-h);
}
.quotation-sheet-table input:focus,
.quotation-sheet-table textarea:focus{
    box-shadow:inset 0 0 0 2px rgba(30,136,229,.18);
}
.quotation-supplier-card{padding-top:20px;}
.soft-card-item{border:1px solid #dce7f2;border-radius:16px;padding:14px;background:linear-gradient(180deg, #fff, #fbfdff);box-shadow:var(--shadow-soft);}
.muted-empty{padding:18px;border:1px dashed #cbd5e1;border-radius:16px;background:rgba(255,255,255,.72);}
.note-head{display:flex;justify-content:space-between;gap:10px;align-items:flex-start;}
.tag-cloud{margin-top:8px;margin-bottom:8px;color:#334155;}
.tag-chip{display:inline-block;padding:3px 8px;border-radius:999px;margin:0 6px 6px 0;}
.note-tag-chip{background:rgba(255,255,255,.6);}
.task-tag-chip{background:#eef2ff;color:#3730a3;}
.attachment-stack{margin-top:12px;display:flex;flex-direction:column;gap:4px;}
.share-note{margin-top:12px;color:#334155;}
.action-bar{display:flex;flex-wrap:wrap;gap:8px;align-items:center;}
.action-bar-card{margin-bottom:16px;}
.option-row{display:flex;gap:12px;flex-wrap:wrap;padding-top:10px;}
.option-chip{display:flex;gap:6px;align-items:center;font-weight:400;}
.option-chip input[type="checkbox"],
.option-chip input[type="radio"]{width:auto;margin:0;}
.inline-form{display:inline;}
.inline-form-flex{display:inline-flex;gap:8px;align-items:center;flex-wrap:wrap;}
.stack-actions{display:flex;flex-direction:column;gap:8px;margin-top:14px;}
.table-wrap.spaced{margin-top:14px;}
.section-top-actions{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap;}
.section-top-actions.compact{margin-top:10px;}
.table-summary-bar{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;margin-top:8px;}
.alert.compact{margin-bottom:12px;}
.detail-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;}
.detail-item{background:#f6f9fd;padding:10px 12px;border-radius:12px;font-size:12px;border:1px solid #e2eaf3;}
.detail-item strong{display:block;color:#64748b;font-size:11px;text-transform:uppercase;margin-bottom:2px;}
.detail-item.full{grid-column:1/-1;}
.soft-stack{display:flex;flex-direction:column;gap:8px;}
.soft-stack.spaced{margin-top:14px;}
.soft-panel{border:1px solid var(--c-border);border-radius:14px;padding:12px 14px;background:#fbfdff;}
.soft-panel-note{border:1px solid #e2e8f0;border-radius:14px;padding:12px;background:#fbfdff;font-size:12px;}
.soft-panel-top{margin-top:8px;}
.preline{white-space:pre-line;}
.success-accent-card{border-left:4px solid var(--c-success);}
@media(max-width:1180px){
    .quotation-hero,
    .quotation-meta-grid{grid-template-columns:1fr;}
    .quotation-hero-stats{grid-template-columns:repeat(3,minmax(0,1fr));}
}
@media(max-width:760px){
    .quotation-hero-stats{grid-template-columns:1fr;}
    .quotation-title{font-size:24px;}
    .sheet-ribbon-group{border-right:0;padding-right:0;margin-right:0;width:100%;}
    .quotation-sheet-table{min-width:980px;}
}
.success-accent-title{margin:0;border:0;color:var(--c-success);}
.scroll-panel{max-height:340px;overflow-y:auto;border:1px solid var(--c-border);border-radius:8px;padding:10px;}
.evidence-tabs{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:12px;}
.evidence-cat-title{font-weight:700;font-size:12px;color:var(--c-muted);margin:8px 0 4px;}
.evidence-row{display:flex;align-items:flex-start;gap:8px;padding:5px 4px;cursor:pointer;border-radius:5px;transition:background .1s;}
.evidence-row:hover{background:#f1f5f9;}
.evidence-row input[type="checkbox"]{width:auto;margin:2px 0 0;}
.evidence-row strong{font-size:12px;display:block;}
.bullet-list-compact{margin:6px 0 0 18px;font-size:12px;line-height:1.6;}
.bullet-list-tight{margin:4px 0 0 16px;font-size:12px;line-height:1.7;}
.editor-textarea{font-family:Georgia,serif;font-size:13px;}
.select-inline{width:auto;margin-top:0;}
@media(max-width:700px){.detail-grid{grid-template-columns:1fr;}}

/* ── Evidence / seals / signing UI ── */
.layout-3col{display:grid;grid-template-columns:220px minmax(0,1fr) 320px;gap:22px;}
.cat-sidebar{display:flex;flex-direction:column;gap:2px;}
.cat-btn{display:flex;align-items:center;justify-content:space-between;padding:10px 12px;border-radius:14px;cursor:pointer;text-decoration:none;color:var(--c-text);font-size:13px;transition:background .12s,transform .12s,border-color .12s;border:1px solid transparent;}
.cat-btn:hover{background:#eef4fa;text-decoration:none;transform:translateX(2px);}
.cat-btn.active{background:linear-gradient(135deg, #15273f 0%, #224066 100%);color:#fff;box-shadow:0 8px 22px rgba(20,39,63,.18);}
.cat-btn.active .cat-count{background:rgba(255,255,255,.25);}
.cat-count{background:var(--c-border);border-radius:99px;font-size:11px;font-weight:600;padding:2px 8px;min-width:22px;text-align:center;}
.ev-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(285px,1fr));gap:16px;}
.ev-card{background:linear-gradient(180deg, #fff, #fbfdff);border:1px solid #dbe5f1;border-radius:18px;padding:16px;transition:box-shadow .18s,transform .18s,border-color .18s;display:flex;flex-direction:column;gap:8px;box-shadow:var(--shadow-soft);}
.ev-card:hover{box-shadow:0 18px 32px rgba(17,24,39,.10);transform:translateY(-2px);border-color:#c9d9ec;}
.ev-title{font-weight:700;font-size:14px;line-height:1.35;}
.ev-meta{font-size:11px;color:var(--c-muted);display:flex;flex-wrap:wrap;gap:7px;}
.ev-actions{display:flex;gap:6px;margin-top:auto;padding-top:8px;border-top:1px solid var(--c-border);flex-wrap:wrap;}
.compact-card{padding:14px;}
.empty-state{padding:40px;text-align:center;color:var(--c-muted);}
.empty-state-icon{font-size:32px;line-height:1;margin:0 0 8px;}
.required-mark{color:var(--c-danger);}
.simple-list{font-size:13px;line-height:1.7;margin:0 0 0 18px;padding:0;}
.simple-list.compact{font-size:12px;line-height:1.8;}
.media-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:16px;margin-top:12px;}
.media-tile{border:1px solid var(--c-border);border-radius:8px;padding:14px;text-align:center;background:#fafafa;}
.media-thumb{max-width:120px;max-height:80px;object-fit:contain;margin-bottom:8px;}
.media-thumb-placeholder{margin-bottom:8px;}
.media-title{font-size:13px;font-weight:600;margin:0 0 8px;}
.logo-thumb{width:44px;height:44px;object-fit:contain;border:1px solid #e2e8f0;border-radius:8px;padding:4px;background:#fff;}
.center-actions{display:flex;gap:8px;justify-content:center;flex-wrap:wrap;margin-top:8px;}
.inline-form-reset{margin:0;}
.form-card-hidden{display:none;}
.option-chip-row{display:flex;align-items:flex-end;}
.soft-card-muted{margin-top:16px;background:#f8fafc;}
.hint-end{display:flex;align-items:end;}
.hint-end .form-hint{margin:0;}
.status-active{color:#059669;}
.status-active.fw-semibold{font-weight:600;}
.status-warning{color:#b45309;}
.status-danger{color:#dc2626;}
.code-secret{font-size:16px;letter-spacing:2px;user-select:all;}
.code-uri{font-size:12px;word-break:break-all;user-select:all;}
.totp-box{display:grid;grid-template-columns:180px 1fr;gap:18px;align-items:center;}
.totp-qr{background:#fff;border:1px solid #cbd5e1;border-radius:8px;padding:12px;min-height:160px;display:flex;align-items:center;justify-content:center;}
.perm-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:14px;}
.perm-group{border:1px solid #e2e8f0;border-radius:10px;padding:12px;}
.perm-group h4{margin:0 0 10px;font-size:14px;}
.perm-item{display:flex;gap:8px;align-items:flex-start;margin:0 0 8px;}
@media(max-width:700px){.totp-box{grid-template-columns:1fr;}}

/* ── Dashboard / tasks / notes ── */
.quick-access{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:12px;}
.quick-access .btn{justify-content:center;min-height:48px;}
.quick-access.compact{grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:8px;}
.quick-access.compact .btn{min-height:34px;padding:6px 10px;font-size:12px;}
.finance-filter-actions{max-width:330px;}
.finance-bulk-actions{min-width:260px;}
.finance-bulk-panel .card-title{margin-bottom:6px;}
.finance-bulk-panel .form-hint{margin-top:0;font-size:12px;line-height:1.35;}
.finance-bulk-grid{align-items:end;}
.finance-bulk-actions{display:flex;flex-wrap:wrap;align-items:flex-end;gap:6px;min-width:0;}
.finance-bulk-actions .btn{min-height:34px;padding:6px 10px;font-size:12px;line-height:1.1;}
.finance-bulk-actions label{margin:0;font-size:12px;line-height:1.2;}
.finance-bulk-actions input[type="checkbox"]{transform:translateY(1px);}
.finance-bulk-panel input,
.finance-bulk-panel select{min-height:36px;font-size:13px;}
.useful-links-grid{display:grid;gap:14px;margin-top:16px;}
.useful-link-card{display:flex;gap:12px;align-items:center;padding:16px;border:1px solid #dbe4ee;border-radius:18px;background:linear-gradient(180deg, #fff, #fafdff);text-decoration:none;color:#0f172a;box-shadow:var(--shadow-soft);}
.useful-link-card:hover{text-decoration:none;box-shadow:0 16px 30px rgba(15,23,42,.10);transform:translateY(-2px);}
.useful-link-thumb{object-fit:contain;border-radius:10px;border:1px solid #e2e8f0;padding:6px;background:#fff;}
.useful-link-fallback{border-radius:10px;border:1px solid #e2e8f0;display:flex;align-items:center;justify-content:center;background:#f8fafc;font-size:11px;color:#64748b;}
.useful-links-grid.comfortable{grid-template-columns:repeat(auto-fit,minmax(180px,1fr));}
.useful-links-grid.cozy{grid-template-columns:repeat(auto-fit,minmax(160px,1fr));}
.useful-links-grid.compact{grid-template-columns:repeat(auto-fit,minmax(140px,1fr));}
.useful-links-grid.dense{grid-template-columns:repeat(auto-fit,minmax(120px,1fr));}
.useful-links-grid.comfortable .useful-link-thumb,
.useful-links-grid.comfortable .useful-link-fallback{width:54px;height:54px;}
.useful-links-grid.cozy .useful-link-thumb,
.useful-links-grid.cozy .useful-link-fallback{width:42px;height:42px;}
.useful-links-grid.compact .useful-link-thumb,
.useful-links-grid.compact .useful-link-fallback{width:34px;height:34px;}
.useful-links-grid.dense .useful-link-thumb,
.useful-links-grid.dense .useful-link-fallback{width:28px;height:28px;}
.count-badges{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px;}
.count-badges .badge{padding:6px 10px;font-size:11px;line-height:1.2;}
.notes-preview-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px;margin-top:14px;}
.preline{white-space:pre-line;}
.kanban-board{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;}
.kanban-column{background:linear-gradient(180deg, rgba(255,255,255,.85), rgba(245,249,253,.95));border:1px solid #dbe4ee;border-radius:20px;padding:16px;min-height:280px;box-shadow:var(--shadow-soft);}
.kanban-column-title{margin-top:0;}
.kanban-card{background:linear-gradient(180deg, #ffffff, #fbfdff);border:1px solid #dbe4ee;border-radius:18px;padding:14px;margin-bottom:12px;box-shadow:0 10px 20px rgba(15,23,42,.06);}
.kanban-card h3{margin:0 0 8px;font-size:15px;}
.kanban-meta{display:flex;flex-wrap:wrap;gap:6px;margin:10px 0;}
.kanban-badge{display:inline-flex;align-items:center;padding:3px 8px;border-radius:999px;font-size:11px;font-weight:700;background:#e2e8f0;color:#334155;}
.kanban-badge.alta{background:#fee2e2;color:#991b1b;}
.kanban-badge.urgente{background:#fecaca;color:#7f1d1d;}
.kanban-badge.media{background:#fef3c7;color:#92400e;}
.kanban-badge.baixa{background:#dcfce7;color:#166534;}
.kanban-badge.enviada{background:#dbeafe;color:#1d4ed8;}
.kanban-badge.em_analise{background:#e0e7ff;color:#4338ca;}
.kanban-badge.aprovada{background:#dcfce7;color:#166534;}
.kanban-badge.bo{background:#fee2e2;color:#991b1b;}
.assignee-list,.attachment-list{display:flex;flex-direction:column;gap:4px;}
.task-actions,.note-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px;}
.notes-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:16px;}
.note-card{border-radius:22px;padding:18px;min-height:220px;box-shadow:0 14px 30px rgba(15,23,42,.10);border:1px solid rgba(15,23,42,.08);}
.note-card.amarelo{background:linear-gradient(180deg, #fff4bf, #fde89d);}
.note-card.azul{background:linear-gradient(180deg, #e1efff, #cfe4ff);}
.note-card.verde{background:linear-gradient(180deg, #dff8ea, #cbf0db);}
.note-card.rosa{background:linear-gradient(180deg, #fde8f4, #fad7ea);}
.note-card.cinza{background:linear-gradient(180deg, #eef2f7, #e1e7ee);}
.note-meta{font-size:12px;color:#334155;margin:10px 0;}
.nowrap-cell{white-space:nowrap;}
@media (max-width:980px){.kanban-board{grid-template-columns:1fr;}}

/* ── Chat / setup ── */
.chat-page {
    margin: 0;
    padding: 0;
    height: 100vh;
    overflow: hidden;
    background: #fff;
}
.chat-page .chat-shell {
    width: 100%;
    height: 100vh;
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 0;
    padding: 0;
    background: #f0f2f5;
}
.chat-page .chat-sidebar {
    background: #ffffff;
    border-right: 1px solid #d1d5db;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: thin;
}
.chat-page .chat-section-title {
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: .5px;
    margin: 16px 14px 6px;
}
.chat-page .chat-users {
    max-height: 35vh;
    overflow-y: auto;
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 8px;
}
.chat-page .chat-sidebar-lists {
    flex: 1;
    overflow-y: auto;
}
.chat-page .chat-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    margin: 0;
    border-radius: 0;
    border: none;
    border-bottom: 1px solid #f8fafc;
    color: #0f172a;
    text-decoration: none;
    position: relative;
    background: #fff;
    transition: background .15s;
    cursor: pointer;
}
.chat-page .chat-item:hover {
    background: #f8fafc;
    text-decoration: none;
}
.chat-page .chat-item.active {
    background: #3390ec;
    color: #fff;
}
.chat-page .chat-item.active .text-muted {
    color: #d1e4f9;
}
.chat-page .chat-item-text {
    flex: 1;
    min-width: 0;
    line-height: 1.3;
}
.chat-page .chat-item-title {
    font-weight: 600;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.chat-page .chat-item-sub {
    font-size: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.chat-page .chat-avatar-circle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, #60a5fa, #3b82f6);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
    flex-shrink: 0;
}
.chat-page .chat-item.active .chat-avatar-circle {
    background: #fff;
    color: #3390ec;
}
.chat-page .chat-unread {
    display: flex;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: #10b981;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.chat-page .chat-item.active .chat-unread {
    background: #fff;
    color: #3390ec;
}
.chat-page .presence-dot {
    position: absolute;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #cbd5e1;
    border: 2px solid #fff;
    right: 0;
    bottom: 0;
}
.chat-page .presence-dot.on { background: #10b981; }
.chat-page .chat-item.active .presence-dot { border-color: #3390ec; }
.chat-page .avatar-wrapper { position: relative; }

.chat-page .chat-main {
    display: flex;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    background: #e4ebf1;
}
.chat-page .chat-window {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
    overflow: hidden;
}
.chat-page .chat-window .panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 18px;
    background: #fff;
    border-bottom: 1px solid #d1d5db;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
    z-index: 10;
}
.chat-page .chat-window .panel-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}
.chat-page .chat-messages {
    flex: 1 1 0;
    overflow-y: auto;
    min-height: 0;
    padding: 20px;
    display: flex;
    flex-direction: column;
}
.chat-page .chat-message-row {
    display: flex;
    align-items: flex-end;
    margin-bottom: 14px;
    max-width: 85%;
    align-self: flex-start;
}
.chat-page .chat-message-row.mine {
    align-self: flex-end;
    flex-direction: row-reverse;
}
.chat-page .chat-bubble {
    padding: 8px 12px;
    background: #ffffff;
    color: #0f172a;
    border-radius: 14px;
    border-bottom-left-radius: 2px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
    position: relative;
    font-size: 14px;
    line-height: 1.45;
}
.chat-page .chat-message-row.mine .chat-bubble {
    background: #effdde;
    border-radius: 14px;
    border-bottom-right-radius: 2px;
    border-bottom-left-radius: 14px;
}
.chat-page .chat-meta {
    font-size: 11px;
    color: #64748b;
    margin-bottom: 4px;
    display: flex;
    justify-content: space-between;
    gap: 12px;
}
.chat-page .chat-message-row.mine .chat-meta {
    color: #5d9e5b;
}
.chat-page .chat-composer {
    flex-shrink: 0;
    background: #f0f2f5;
    padding: 10px 20px 14px;
}
.chat-page .chat-selected-files {
    margin-top: 8px;
    padding: 0 14px;
    font-size: 12px;
    color: #1e40af;
    line-height: 1.4;
    word-break: break-word;
}
.chat-page .chat-composer-inner {
    display: flex;
    gap: 10px;
    align-items: flex-end;
    background: #fff;
    padding: 8px 14px;
    border-radius: 24px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.chat-page .chat-composer textarea {
    flex: 1;
    border: none;
    box-shadow: none;
    background: transparent;
    min-height: 24px;
    max-height: 120px;
    margin: 0;
    padding: 4px 0;
    resize: none;
    line-height: 1.4;
}
.chat-page .chat-composer textarea:focus {
    box-shadow: none;
    background: transparent;
}
.chat-page .chat-composer .file-input-wrapper {
    position: relative;
    overflow: hidden;
    display: inline-block;
    cursor: pointer;
}
.chat-page .chat-composer .file-input-wrapper input[type="file"] {
    position: absolute;
    left: 0;
    top: 0;
    opacity: 0;
    cursor: pointer;
    height: 100%;
}
.chat-page .chat-composer-btn {
    background: transparent;
    color: #3b82f6;
    border: none;
    cursor: pointer;
    padding: 6px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s;
    font-size: 18px;
    line-height: 1;
}
.chat-page .chat-composer-btn:hover { background: #f1f5f9; }

.chat-page .sidebar-form {
    padding: 16px;
    border-top: 1px solid #e2e8f0;
    background: #f8fafc;
}
.chat-page .sidebar-form label { font-size: 12px; margin-top: 8px; }
.chat-page .sidebar-form select, .chat-page .sidebar-form input { font-size: 13px; }

@media(max-width: 800px) {
    .chat-page .chat-shell { grid-template-columns: 1fr; }
    .chat-page .chat-shell.no-group .chat-main { display: none; }
    .chat-page .chat-shell.has-group .chat-sidebar { display: none; }
}

/* ── Width utilities / residual layouts ── */
.w-4p{width:4%;}
.w-5p{width:5%;}
.w-7p{width:7%;}
.w-8p{width:8%;}
.w-10p{width:10%;}
.w-12p{width:12%;}
.w-13p{width:13%;}
.w-14p{width:14%;}
.w-17p{width:17%;}
.w-18p{width:18%;}
.w-20p{width:20%;}
.w-22p{width:22%;}
.w-24p{width:24%;}
.w-28p{width:28%;}
.w-34p{width:34%;}
.w-35p{width:35%;}
.select-min-260{min-width:260px;}
.soft-card-tight{margin-top:10px;padding:14px;}
.step-flow{display:flex;gap:20px;flex-wrap:wrap;align-items:center;padding:14px 20px;margin-bottom:0;}
.step-separator{color:#cbd5e1;}
.page-grid-top{margin-top:16px;}
.preview-toolbar{margin:12px 0;}
.preview-toolbar-row{display:flex;gap:8px;align-items:center;margin-top:6px;flex-wrap:wrap;}
.page-info{font-size:13px;}
.pdf-preview-shell{max-width:780px;}
.pdf-container{position:relative;border:2px solid var(--c-border);border-radius:8px;overflow:hidden;background:#eee;cursor:crosshair;}
.pdf-canvas{display:block;width:100%;}
.sig-overlay{position:absolute;border:2px dashed #2563eb;background:rgba(37,99,235,.12);cursor:move;display:none;min-width:60px;min-height:30px;}
.sig-overlay .sig-handle{position:absolute;right:-6px;bottom:-6px;width:12px;height:12px;background:#2563eb;border-radius:50%;cursor:se-resize;}
.step-badge{display:inline-flex;align-items:center;justify-content:center;width:28px;height:28px;border-radius:50%;background:var(--c-primary);color:#fff;font-weight:700;font-size:13px;margin-right:8px;}
.step-badge.done{background:var(--c-success);}
.step-badge.active{background:var(--c-accent);}
@media(max-width:900px){.layout-3col{grid-template-columns:1fr;}}

/* ── Admin layout ── */
.admin-aside{background:var(--c-primary);width:200px;min-height:calc(100vh - 60px);padding:20px 0;float:left;}
.admin-aside a{display:block;color:#94a3b8;padding:10px 20px;font-size:13px;transition:background .15s;}
.admin-aside a:hover,.admin-aside a.active{background:var(--c-primary-lt);color:#fff;text-decoration:none;}
.admin-content{margin-left:220px;padding:24px 20px;}
@media(max-width:700px){.admin-aside{display:none;}.admin-content{margin-left:0;}}

/* ── Misc ── */
.mt-0{margin-top:0;}.mt-1{margin-top:8px;}.mt-2{margin-top:16px;}.mt-3{margin-top:24px;}
.mb-0{margin-bottom:0;}.mb-1{margin-bottom:8px;}
.text-muted{color:var(--c-muted);}
.text-small{font-size:12px;}
.text-right{text-align:right;}
.text-center{text-align:center;}
.fw-bold{font-weight:700;}
.notice{background:#fff8e6;border:1px solid #fcd34d;padding:10px 13px;border-radius:7px;font-size:13px;margin-bottom:12px;}
.divider{border:0;border-top:1px solid var(--c-border);margin:16px 0;}
.section-heading{font-size:13px;font-weight:700;color:var(--c-muted);text-transform:uppercase;letter-spacing:.5px;margin:18px 0 8px;}

/* ── Password manager ── */
.page-grid > section,
.page-grid > aside,
.password-list,
.password-card,
.password-field,
.password-field > div,
.password-actions,
.password-generator,
#share-rows,
#share-rows > div{min-width:0;}
.password-list{display:grid;gap:14px;}
.password-card{border:1px solid #dbe4ee;border-radius:20px;background:linear-gradient(180deg, #fff, #fbfdff);padding:18px;box-shadow:0 14px 28px rgba(15,23,42,.08);overflow:hidden;}
.password-header{display:flex;justify-content:space-between;gap:12px;align-items:flex-start;flex-wrap:wrap;}
.password-meta{display:flex;gap:8px;flex-wrap:wrap;margin-top:8px;}
.password-field{display:grid;grid-template-columns:140px 1fr auto;gap:10px;align-items:center;padding:10px 0;border-top:1px solid #edf2f8;}
.password-field:first-of-type{border-top:0;padding-top:0;}
.password-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:14px;}
.password-secret{font-family:Consolas,Monaco,monospace;font-size:12px;word-break:break-word;overflow-wrap:anywhere;}
.password-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;}
.password-stat{padding:16px;border:1px solid #dbe4ee;border-radius:18px;background:linear-gradient(180deg, #fff, #fbfdff);box-shadow:var(--shadow-soft);}
.vault-chip{display:inline-flex;align-items:center;padding:5px 10px;border-radius:999px;background:#e7f1ff;color:#1b5fbf;font-size:11px;font-weight:700;}
.owner-chip{display:inline-flex;align-items:center;padding:5px 10px;border-radius:999px;background:#f1f5fa;color:#334155;font-size:11px;}
.password-generator{margin-top:10px;padding:14px;border:1px solid #dbe4ee;border-radius:18px;background:linear-gradient(180deg, #f8fbfe, #f3f7fb);}
.password-generator-row{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin-top:8px;}
.password-generator-row input[type="number"]{width:90px;margin-top:0;}
.password-page-user{color:#94a3b8;font-size:12px;}
.password-toolbar{display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap;}
.password-toolbar-actions,
.password-inline-actions,
.password-inline-actions-wrap,
.password-form-actions,
.vault-actions{display:flex;gap:8px;flex-wrap:wrap;}
.password-form-actions{margin-top:12px;}
.vault-actions{margin-top:10px;}
.password-title{margin:0;border:0;padding:0;}
.password-intro{margin-top:8px;}
.password-stats-block{margin-top:16px;}
.password-filter-form{display:flex;gap:8px;flex-wrap:wrap;align-items:center;}
.password-search-input{max-width:340px;}
.password-select-inline{width:auto;margin-top:0;}
.password-item-title{font-size:16px;}
.password-shares{margin-top:12px;}
.vault-list{display:grid;gap:10px;}
.vault-card{border:1px solid #dbe4ee;border-radius:12px;padding:12px;background:#fff;}
.vault-card.active{border-color:#1b5fbf;background:linear-gradient(180deg,#f8fbff,#eef5ff);box-shadow:0 10px 24px rgba(27,95,191,.12);}
.password-generator-label,
.password-checkbox-row{margin:0;font-weight:400;display:flex;gap:6px;align-items:center;}
.password-checkbox-row{gap:8px;margin:14px 0 0;}
.password-checkbox-row input[type="checkbox"],
.password-generator-label input[type="checkbox"]{width:auto;margin:0;}
.password-feedback{margin-top:8px;}
.share-rows{display:grid;gap:8px;margin-top:6px;}
.share-rows-empty{padding:10px 12px;border:1px dashed var(--c-border);border-radius:8px;background:#f8fafc;color:var(--c-muted);font-size:12px;}
.password-field a{overflow-wrap:anywhere;word-break:break-word;}
.password-notes{white-space:pre-line;overflow-wrap:anywhere;word-break:break-word;}
.password-workspace-card{display:grid;gap:16px;}
.password-workspace-head{align-items:center;}
.password-tab-bar{display:flex;gap:8px;flex-wrap:wrap;padding:6px;border:1px solid #d7e4f0;border-radius:18px;background:linear-gradient(180deg,#f9fbfe,#f1f6fb);}
.password-tab-btn{appearance:none;border:0;border-radius:14px;padding:10px 14px;background:transparent;color:#476077;font-weight:700;cursor:pointer;transition:background .16s ease,color .16s ease,transform .16s ease;}
.password-tab-btn.active{background:#1b5fbf;color:#fff;box-shadow:0 10px 22px rgba(27,95,191,.24);}
.password-tab-btn:hover{transform:translateY(-1px);}
.password-tab-panel{display:grid;gap:14px;}
.password-vault-directory{display:grid;gap:10px;}
.password-access-note{padding:12px 14px;border:1px solid #d8e4f0;border-radius:14px;background:linear-gradient(180deg,#f9fcff,#f1f7fd);}
.password-vault-item-grid{display:grid;gap:10px;}
.password-vault-item-card{padding:14px;border:1px solid #dbe4ee;border-radius:16px;background:linear-gradient(180deg,#fff,#fbfdff);}
.password-share-summary-list{display:grid;gap:8px;}
@media(max-width:900px){.password-stats{grid-template-columns:1fr;}.password-field{grid-template-columns:1fr;}}

/* ── Scoped Visual Refresh ── */
.dashboard-page .site-main > .card,
.tasks-page .site-main > .page-grid > section > .card:first-child,
.notes-page .site-main > .page-grid > section > .card:first-child,
.passwords-page .site-main > .card{
    border:1px solid #d5e1ee;
    box-shadow:0 18px 36px rgba(15,23,42,.09);
}

.dashboard-page .quick-access .btn{
    min-height:52px;
    border-radius:16px;
    font-weight:700;
}
.dashboard-page .quick-access .btn-ghost{
    background:linear-gradient(180deg, #ffffff, #f6f9fd);
}
.dashboard-page .useful-link-card{
    gap:14px;
    border-radius:20px;
    border-color:#cfdeed;
}
.dashboard-page .useful-link-card strong{
    font-size:14px;
    line-height:1.25;
}
.dashboard-page .notes-preview-grid .soft-card-item,
.dashboard-page .soft-card-list .soft-card-item{
    border-radius:18px;
}

.tasks-page .page-grid{grid-template-columns:minmax(0,2fr) minmax(320px,1fr);}
.tasks-page .kanban-board{gap:18px;align-items:start;}
.tasks-page .kanban-column{
    border-radius:22px;
    background:linear-gradient(180deg, #fdfefe, #f0f6fb);
    border:1px solid #d7e4f0;
}
.tasks-page .kanban-column-title{
    font-size:15px;
    font-weight:800;
    color:#27384d;
    margin-bottom:12px;
}
.tasks-page .kanban-card{
    border-radius:18px;
    border-color:#d6e2ef;
    background:linear-gradient(180deg, #ffffff, #fbfdff);
    box-shadow:0 12px 24px rgba(15,23,42,.08);
    transition:transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}
.tasks-page .kanban-card:hover{
    transform:translateY(-2px);
    box-shadow:0 18px 30px rgba(15,23,42,.12);
    border-color:#c4d7ea;
}
.tasks-page .kanban-badge{padding:4px 10px;}
.tasks-page #task-form-card{
    position:sticky;
    top:92px;
}

.notes-page .page-grid{grid-template-columns:minmax(0,2fr) minmax(320px,1fr);}
.notes-page .notes-grid{gap:18px;}
.notes-page .note-card{
    border-radius:24px;
    border:1px solid rgba(23,35,53,.10);
    box-shadow:0 16px 30px rgba(15,23,42,.12);
    display:flex;
    flex-direction:column;
}
.notes-page .note-card .preline{
    flex:1 1 auto;
    line-height:1.5;
}
.notes-page .note-actions{margin-top:14px;}
.notes-page #note-form-card{
    position:sticky;
    top:92px;
}

.passwords-page .page-grid{grid-template-columns:minmax(0,2fr) minmax(320px,1fr);}
.passwords-page .password-toolbar{
    align-items:flex-end;
    gap:14px;
}
.passwords-page .password-toolbar-actions .btn{
    border-radius:14px;
    min-height:38px;
}
.passwords-page .password-stats{gap:14px;}
.passwords-page .password-stat{
    border-radius:18px;
    border-color:#d4e1ee;
    box-shadow:0 10px 22px rgba(15,23,42,.08);
}
.passwords-page .password-card{
    border-radius:22px;
    border-color:#d5e3f1;
    box-shadow:0 16px 30px rgba(15,23,42,.10);
    transition:transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}
.passwords-page .password-card:hover{
    transform:translateY(-2px);
    box-shadow:0 20px 34px rgba(15,23,42,.12);
    border-color:#c4d8ec;
}
.passwords-page .password-field{
    padding:12px 0;
    grid-template-columns:150px minmax(0,1fr) auto;
}
.passwords-page .password-actions .btn{border-radius:12px;}
.passwords-page #vault-form-card,
.passwords-page #item-form-card,
.passwords-page #import-form-card{
    position:sticky;
    top:92px;
}

.hr-page .site-main{max-width:1520px;}
.hr-page .hr-main-grid{grid-template-columns:minmax(0,1.9fr) minmax(340px,1fr);align-items:start;}
.hr-hero-card{display:flex;justify-content:space-between;gap:20px;align-items:center;background:
    radial-gradient(circle at top left, rgba(32,111,255,.12), transparent 36%),
    linear-gradient(135deg, #f7fbff 0%, #ffffff 48%, #eef6ff 100%);}
.hr-hero-copy{max-width:760px;}
.hr-eyebrow{display:inline-block;padding:6px 12px;border-radius:999px;background:#dcecff;color:#1858b8;font-size:11px;font-weight:800;letter-spacing:.08em;text-transform:uppercase;}
.hr-hero-title{margin-top:12px;margin-bottom:8px;font-size:32px;}
.hr-hero-text{max-width:720px;}
.hr-hero-actions{display:flex;gap:10px;flex-wrap:wrap;align-items:center;}
.hr-stat-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin:18px 0 22px;}
.hr-stat-card{display:flex;flex-direction:column;gap:6px;min-height:128px;justify-content:center;background:linear-gradient(180deg,#fff,#f8fbff);}
.hr-stat-card.hr-stat-accent{background:linear-gradient(135deg,#f3f8ff 0%,#e9f2ff 100%);}
.hr-stat-label{font-size:12px;text-transform:uppercase;letter-spacing:.08em;color:#5c7288;font-weight:700;}
.hr-stat-value{font-size:38px;line-height:1;color:#12304d;}
.hr-chip{display:inline-flex;align-items:center;justify-content:center;padding:5px 10px;border-radius:999px;font-size:11px;font-weight:800;letter-spacing:.02em;background:#e2e8f0;color:#334155;}
.hr-chip.active,.hr-chip.approved{background:#dcfce7;color:#166534;}
.hr-chip.on_leave,.hr-chip.pending,.hr-chip.vacation{background:#dbeafe;color:#1d4ed8;}
.hr-chip.inactive,.hr-chip.denied,.hr-chip.closed,.hr-chip.canceled{background:#e5e7eb;color:#374151;}
.hr-chip.paused{background:#fef3c7;color:#92400e;}
.hr-chip.completed,.hr-chip.redeemed{background:#ede9fe;color:#6d28d9;}
.hr-table-actions{display:flex;gap:8px;flex-wrap:wrap;}
.hr-occurrence-list,.hr-program-list{display:grid;gap:12px;}
.hr-occurrence-card,.hr-program-card{border-radius:18px;}
.hr-occurrence-head{display:flex;justify-content:space-between;gap:12px;align-items:flex-start;}
.hr-occurrence-meta{display:flex;gap:10px;flex-wrap:wrap;margin-top:10px;color:#526579;font-size:12px;}
.hr-card-note{margin-top:10px;}
.hr-card-actions{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin-top:14px;}
.hr-program-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;}
.hr-subsection-title{font-size:12px;font-weight:800;text-transform:uppercase;letter-spacing:.08em;color:#607489;margin-bottom:10px;}
.hr-side-card{position:static;}
.hr-side-card + .hr-side-card{margin-top:18px;}
.hr-timeline,.hr-ranking{display:grid;gap:10px;}
.hr-timeline-item{padding:12px 14px;border:1px solid #dce7f2;border-radius:14px;background:#fcfdff;}
.hr-ranking-row{display:grid;grid-template-columns:34px minmax(0,1fr) auto;gap:12px;align-items:center;padding:12px 14px;border:1px solid #dce7f2;border-radius:14px;background:#fcfdff;}
.hr-ranking-position{display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;border-radius:50%;background:#1f4fa8;color:#fff;font-weight:800;}
.hr-page .filter-form{gap:10px;}
.hr-page .filter-inline-input-sm{min-width:220px;}

@media(max-width:1100px){
    .tasks-page .page-grid,
    .notes-page .page-grid,
    .passwords-page .page-grid,
    .hr-page .hr-main-grid,
    .hr-stat-grid,
    .hr-program-grid{
        grid-template-columns:1fr;
    }
    .tasks-page #task-form-card,
    .notes-page #note-form-card,
    .passwords-page #vault-form-card,
    .passwords-page #item-form-card,
    .passwords-page #import-form-card,
    .hr-page .hr-side-card{
        position:static;
    }
    .hr-hero-card{flex-direction:column;align-items:flex-start;}
}

/* ── Print ── */
@media print{
    .site-header,.header-nav,.filter-bar,.card.no-print,.btn,.alert,
    .admin-aside,form,.table-actions{display:none!important;}
    .preview-wrap{background:#fff;padding:0;}
    .preview-a4{box-shadow:none;border:0;}
    body{background:#fff;}
}
