/* Shared Avia spacing and compact operational components; retain the original palette. */
:root{--space-1:.375rem;--space-2:.75rem;--space-3:1rem;--space-4:1.5rem}
main{font-size:.9rem}main h1{font-size:1.65rem;font-weight:900;line-height:1.25}main h2{font-weight:700}
.page-heading{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:var(--space-3);margin-bottom:var(--space-4)}
.page-heading p,.field-help{font-size:.8rem;color:var(--muted)}
.section-stack>*+*{margin-top:var(--space-3)}main>.card+ .card,main>form+section{margin-top:var(--space-3)}
.card>h2+p,.card>h2+form,.card>h3+form{margin-top:var(--space-2)}
.card>label{display:block}.card>label+label,.card>label+.btn{margin-top:var(--space-2)}
.card>form>label{display:block}.card>form>label+label,.card>form>label+.btn{margin-top:var(--space-2)}
.card form.grid>.btn{align-self:end;justify-self:start}.card>p+.btn{margin-top:var(--space-2)}
.photo-dropzone:focus-within .drop-area{outline:3px solid #60a5fa;outline-offset:3px}
main .form-input{max-width:100%}main input[type=checkbox],main input[type=radio]{flex-shrink:0}
.actions{display:flex;align-items:center;flex-wrap:wrap;gap:var(--space-2)}
.form-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:var(--space-3)}
main label:not(.check-label){font-size:.82rem;font-weight:600}
main label>.form-input,main label>input:not([type=checkbox]):not([type=radio]),main label>select,main label>textarea{margin-top:var(--space-1)}
main label>.field-help{display:block;margin-top:var(--space-1);font-weight:400}
.check-label{display:flex;align-items:center;gap:var(--space-2)}
.filter-bar{display:flex;align-items:end;flex-wrap:wrap;gap:var(--space-2);padding:var(--space-3);margin-bottom:var(--space-3)}
.filter-bar>label{flex:1 1 150px}.filter-bar>label:first-child{flex-grow:2}
.filter-bar details{width:100%}.filter-bar summary{cursor:pointer;color:#334155;font-weight:600;padding:.25rem 0}
.filter-bar details[open]>.form-grid{margin-top:var(--space-2)}
.department-context{display:flex;align-items:center;gap:var(--space-2);background:#eef5fc;border:1px solid #dbe7f4;border-radius:10px;padding:.5rem .75rem;max-width:100%}
.department-context select{min-width:180px;background:#fff}.department-context svg{color:var(--blue);flex-shrink:0}
.table-scroll{overflow-x:auto}.table-modern{text-align:left}.table-modern td,.table-modern th{padding:.6rem .75rem;vertical-align:middle}
.btn{font-size:.82rem;padding:.5rem .75rem;min-height:34px}.btn:hover{filter:brightness(.98)}
.btn:disabled,.action-icon:disabled{opacity:.4;cursor:not-allowed}.btn svg,.nav-link svg,.action-icon svg{flex-shrink:0}
button,a,input,select,summary{touch-action:manipulation}a:focus-visible,button:focus-visible,summary:focus-visible{outline:3px solid #60a5fa;outline-offset:3px}
.nav-link{font-size:.88rem}.nav-link[aria-current=page]{background:var(--blue);color:#fff}
.navigation-card{display:flex;align-items:center;gap:var(--space-3);padding:var(--space-3);transition:border-color .15s,background .15s}
.navigation-card:hover,.metric-link:hover{border-color:#93c5fd;background:#f8fbff}.navigation-card small{display:block;font-weight:400;color:var(--muted);margin-top:.25rem}
.metric-link{cursor:pointer;display:flex;justify-content:space-between;align-items:center;gap:.75rem;border-radius:10px;padding:.65rem;border:1px solid #e7edf4}
.vehicle-tabs{display:flex;flex-wrap:wrap;gap:.5rem;margin:1rem 0}.vehicle-tabs [aria-selected=true]{background:#e8f2ff;border-color:#93c5fd;color:#125fb8}
.price-editor{min-width:155px}.price-editor .form-input{padding:.4rem .5rem;font-variant-numeric:tabular-nums}
.price-editor .actions{gap:.3rem;margin-top:0}.price-editor [data-save-state]{display:block;font-size:.72rem;max-width:180px}
.price-editor .action-icon{width:28px;height:28px;border-radius:7px}.price-editor .action-icon svg{width:16px;height:16px}
.empty-state{padding:1.5rem!important;color:var(--muted);text-align:center}
.catalogue-nav{display:flex;flex-wrap:wrap;gap:.5rem;margin-bottom:1rem}.catalogue-nav a{padding:.4rem .65rem;border-radius:8px;border:1px solid #dbe3ed;background:white}
.catalogue-nav a[aria-current=page]{background:#e8f2ff;border-color:#93c5fd;color:#125fb8;font-weight:700}
.compact-edit>summary{cursor:pointer;list-style:none;display:inline-flex;align-items:center;gap:.4rem;color:#1677e8;font-weight:600}
.compact-edit[open]{min-width:min(420px,70vw)}.compact-edit form{margin-top:.75rem}
@media(max-width:640px){.page-heading{align-items:flex-start}.filter-bar>label{flex-basis:100%}.form-grid{grid-template-columns:1fr}.department-context{width:100%}.department-context label{flex:1}.department-context select{min-width:0}.table-modern{font-size:.8rem}.vehicle-tabs{gap:.375rem}.vehicle-tabs .btn{font-size:.75rem}.compact-edit[open]{min-width:240px}}

/* Shared operational and sales presentation. */
.price-controls{display:flex;align-items:center;gap:4px;flex-wrap:nowrap;min-width:200px}
.price-controls .form-input{width:105px;min-width:90px;padding:.4rem}
.price-controls .actions{flex-wrap:nowrap;gap:3px;margin:0}
.price-controls .action-icon{width:26px;height:28px;border-radius:6px}
[data-price-editor] [data-save-state]{display:block;font-size:.7rem;line-height:1.2;max-width:210px}
button:disabled{opacity:.4;cursor:default}
.vehicle-link{color:#1d4ed8;font-weight:600}
.vehicle-tabs [aria-selected="true"]{background:#10233d;color:#fff;border-color:#10233d;box-shadow:inset 0 -3px #60a5fa}
.vehicle-tabs .btn:hover{border-color:#60a5fa}.priority-active svg{fill:currentColor}
.vehicle-tabs{border-bottom:1px solid #cbd5e1;padding-bottom:8px;margin-bottom:12px}
.vehicle-heading h1{margin-bottom:3px}.vehicle-heading p{font-size:.82rem;color:#64748b}
.content-section{padding:16px}.section-heading{display:flex;align-items:center;gap:7px;font-weight:700;margin-bottom:10px}
.document-section{margin-top:20px;padding-top:16px;border-top:1px solid #e2e8f0}
.file-upload{display:flex;flex-direction:column;gap:6px;padding:12px;background:#f8fafc;border:1px dashed #94a3b8;border-radius:8px;flex:1}
.file-upload input{font-size:.8rem;max-width:100%}.file-upload input::file-selector-button{border:1px solid #cbd5e1;border-radius:6px;padding:6px 10px;background:white;margin-right:10px}
.danger-zone{padding:14px;border:1px solid #fecdd3;border-radius:8px;margin-top:8px}.danger-zone p{font-size:.8rem;color:#64748b}
.sales-summary{padding:18px;display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:16px}
.sales-price{font-size:1.8rem;font-weight:800;color:#10233d}.sales-monthly{font-size:.85rem;color:#475569}
.sales-detail-grid{display:grid;grid-template-columns:1.2fr 1fr;gap:16px}.facts-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.facts-grid dt{font-size:.75rem;color:#64748b}.facts-grid dd{font-weight:600}
.sales-photo{display:inline-block;width:48%;margin:1%;vertical-align:top}.sales-photo img{width:100%;aspect-ratio:4/3;object-fit:cover;border-radius:8px}.sales-photo-main{width:98%}
.pdf-brochure{border-color:#bfdbfe;background:#eff6ff;color:#1d4ed8}
.sidebar-toggle{display:none;margin:0 0 12px auto}
@media(min-width:1024px){.sidebar-toggle{display:flex}.desktop-sidebar,.app-main{transition:width .15s,margin-left .15s}
.sidebar-collapsed .desktop-sidebar{width:76px;padding-left:10px;padding-right:10px}.sidebar-collapsed .app-main{margin-left:76px}
.sidebar-collapsed .nav-link{justify-content:center;padding:12px 8px}.sidebar-collapsed .nav-link span,.sidebar-collapsed .sidebar-footer{display:none}
.sidebar-collapsed .sidebar-brand{padding:0;min-height:35px;margin-bottom:15px}.sidebar-collapsed .sidebar-brand img{max-width:54px}.sidebar-collapsed .sidebar-toggle{margin-right:auto}
}
@media(max-width:767px){.sales-detail-grid{grid-template-columns:1fr}.sales-summary{align-items:flex-start;flex-direction:column}}

.retail-cell{font-size:.75rem;line-height:1.35;max-width:250px;margin-top:5px}.retail-cell .badge{font-size:.7rem;padding:.15rem .4rem}

/* =========================================================
   DASHBOARD V2.1 VISUAL REFRESH
   ========================================================= */

.dashboard-heading{margin-bottom:16px}

.dashboard-top-grid{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:14px;
    margin-bottom:14px;
}

.dashboard-stat{
    min-height:86px;
    display:flex;
    align-items:center;
    gap:14px;
    padding:16px 20px;
    overflow:hidden;
    position:relative;
}

.dashboard-stat-icon{
    width:44px;
    height:44px;
    border-radius:999px;
    display:flex;
    align-items:center;
    justify-content:center;
    flex:none;
}

.dashboard-stat-content{flex:1}
.dashboard-stat-content>span{font-size:.8rem}
.dashboard-stat-content strong{
    display:block;
    font-size:1.65rem;
    line-height:1.05;
}

.dashboard-stat-arrow{display:flex;align-items:center}

.dashboard-stat-blue .dashboard-stat-icon{
    background:#e8f2ff;
    color:#1677e8;
}

.dashboard-stat-yellow{
    background:linear-gradient(90deg,#fff,#fff9e9);
}

.dashboard-stat-yellow .dashboard-stat-icon{
    background:#fff7d6;
    color:#eab308;
}

.dashboard-stat-attention{
    border-color:#f59e0b;
    background:linear-gradient(135deg,#fff,#fff7e6);
    box-shadow:0 5px 18px rgba(245,158,11,.14);
}

.dashboard-stat-attention .dashboard-stat-icon{
    background:#fef3c7;
    color:#d97706;
}

.dashboard-stat-attention .dashboard-stat-content strong{
    color:#b45309;
}


.dashboard-stat-critical{
    border-color:#ef4444;
    background:linear-gradient(135deg,#fff,#fff1f2);
    box-shadow:0 5px 18px rgba(239,68,68,.14);
}

.dashboard-stat-critical .dashboard-stat-icon{
    background:#fee2e2;
    color:#dc2626;
}

.dashboard-stat-critical .dashboard-stat-content strong{
    color:#b91c1c;
}

.dashboard-stat-critical .dashboard-stat-alert-label{
    background:#dc2626;
    color:#fff;
}

.dashboard-stat-alert-label{
    display:inline-flex;
    align-items:center;
    margin-top:5px;
    padding:2px 7px;
    border-radius:999px;
    background:#f59e0b;
    color:#fff;
    font-size:.64rem;
    line-height:1.35;
    font-weight:800;
    letter-spacing:.04em;
    text-transform:uppercase;
}


/* SALE PIPELINE */

.dashboard-sales{
    padding:16px;
    margin-bottom:14px;
    border-color:#bfdbfe;
    background:linear-gradient(135deg,#fff,#f8fbff);
}

.dashboard-section-header{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:16px;
    margin-bottom:12px;
}

.dashboard-section-header h2{
    display:flex;
    align-items:center;
    gap:7px;
    font-weight:800;
}

.dashboard-section-header p{
    margin-top:2px;
    font-size:.78rem;
    color:#64748b;
}

.dashboard-section-action{
    color:#1677e8;
    background:#eff6ff;
    border-color:#bfdbfe;
}

.dashboard-sales-pipeline{
    display:grid;
    grid-template-columns:1fr auto 1fr auto 1fr auto 1fr auto 1fr;
    gap:9px;
    align-items:center;
}

.dashboard-sale-stage{
    min-height:72px;
    display:flex;
    align-items:center;
    gap:11px;
    border-radius:11px;
    padding:11px 13px;
    border:1px solid rgba(148,163,184,.18);
    transition:transform .12s,box-shadow .12s;
}

.dashboard-sale-stage:hover{
    transform:translateY(-1px);
    box-shadow:0 5px 12px rgba(15,23,42,.08);
}

.dashboard-sale-icon{
    display:flex;
    align-items:center;
    justify-content:center;
    flex:none;
}

.dashboard-sale-copy{min-width:0}
.dashboard-sale-copy span{
    display:block;
    font-size:.75rem;
    line-height:1.2;
}

.dashboard-sale-copy strong{
    display:block;
    margin-top:3px;
    font-size:1.45rem;
    line-height:1;
}

.dashboard-sale-blue{background:#eaf4ff;color:#1267c9}
.dashboard-sale-yellow{background:#fff6dc;color:#b76a00}
.dashboard-sale-purple{background:#f4eaff;color:#7e22ce}
.dashboard-sale-green{background:#e7f8ed;color:#15803d}
.dashboard-sale-red{background:#fff0f1;color:#dc2626}

.dashboard-pipeline-arrow{
    font-size:1.2rem;
    color:#475569;
}


/* CLEANING / REPAIR / INSURANCE */

.dashboard-process-grid{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:14px;
}

.dashboard-process-card{
    padding:16px;
    position:relative;
    overflow:hidden;
}

.dashboard-process-title{
    display:flex;
    justify-content:space-between;
    align-items:flex-start;
}

.dashboard-process-title h2{
    display:flex;
    gap:7px;
    align-items:center;
    font-weight:800;
}

.dashboard-watermark{
    position:absolute;
    top:13px;
    right:14px;
    opacity:.10;
    color:#1677e8;
}

.dashboard-metric-list{
    display:flex;
    flex-direction:column;
    gap:8px;
    margin-top:13px;
}

.dashboard-metric-row{
    min-height:44px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:10px;
    padding:8px 10px;
    border:1px solid #e3eaf2;
    border-radius:9px;
    background:rgba(255,255,255,.82);
}

.dashboard-metric-row:hover{
    border-color:#93c5fd;
    background:#f8fbff;
}


/* DAMAGE / OFFERS */

.dashboard-secondary-grid{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:14px;
    margin-top:14px;
}

.dashboard-damage-card{
    padding:16px;
    border-color:#fecaca;
    background:linear-gradient(135deg,#fff,#fffafa);
}

.dashboard-damage-card h2{color:#991b1b}

.dashboard-red-button{
    background:#fff1f2;
    color:#dc2626;
    border:1px solid #fecdd3;
}

.dashboard-offer-card{
    padding:16px;
    border-color:#bfdbfe;
    background:linear-gradient(135deg,#fff,#f5faff);
}

.dashboard-offer-top{
    display:flex;
    gap:10px;
    color:#1677e8;
}

.dashboard-offer-top h2{
    color:#0f172a;
    font-weight:800;
}

.dashboard-offer-top p{
    font-size:.78rem;
    color:#64748b;
}

.dashboard-offer-value{
    min-height:145px;
    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    text-align:center;
}

.dashboard-offer-icon{
    width:50px;
    height:50px;
    display:flex;
    align-items:center;
    justify-content:center;
    border-radius:999px;
    background:#e8f2ff;
    color:#1677e8;
}

.dashboard-offer-value strong{
    font-size:2rem;
    line-height:1;
    margin-top:8px;
}

.dashboard-offer-value b{font-size:.8rem}
.dashboard-offer-value>span:last-child{
    color:#64748b;
    font-size:.75rem;
    margin-top:2px;
}


/* LOCATIONS */

.dashboard-locations{
    padding:16px;
    margin-top:14px;
}

.dashboard-location-grid{
    display:grid;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:10px;
}

.dashboard-location{
    min-height:75px;
    display:flex;
    align-items:center;
    gap:10px;
    padding:11px;
    border-radius:10px;
}

.dashboard-location>span:nth-child(2){flex:1}
.dashboard-location b{
    display:block;
    font-size:.75rem;
    line-height:1.2;
}

.dashboard-location strong{
    display:block;
    font-size:1.35rem;
    line-height:1.15;
}

.dashboard-location small{
    color:#64748b;
    font-size:.68rem;
}

.dashboard-location-icon{
    width:38px;
    height:38px;
    border-radius:999px;
    display:flex;
    align-items:center;
    justify-content:center;
    background:rgba(255,255,255,.65);
}

.dashboard-location-blue{background:#eaf4ff;color:#1267c9}
.dashboard-location-green{background:#e9f9ef;color:#15803d}
.dashboard-location-yellow{background:#fff7df;color:#b76a00}
.dashboard-location-purple{background:#f6edff;color:#7e22ce}


/* ATTENTION */

.dashboard-attention{
    padding:16px;
    margin-top:14px;
    border-color:#fecaca;
    background:linear-gradient(135deg,#fff,#fffafa);
}

.dashboard-attention-icon{
    width:21px;
    height:21px;
    border-radius:999px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    background:#ef4444;
    color:#fff;
    font-weight:900;
    font-size:.75rem;
}

.dashboard-attention-list{
    display:flex;
    flex-direction:column;
    gap:5px;
}

.dashboard-attention-row{
    display:grid;
    grid-template-columns:minmax(220px,1fr) 2fr auto;
    align-items:center;
    gap:14px;
    padding:8px 10px;
    border-radius:8px;
    background:#fff4f4;
}

.dashboard-attention-row>div a{
    font-weight:700;
    text-decoration:underline;
}

.dashboard-attention-message{
    color:#dc2626;
    font-size:.78rem;
}

.dashboard-attention-message b{
    display:inline-flex;
    width:16px;
    height:16px;
    align-items:center;
    justify-content:center;
    margin-right:5px;
    border-radius:999px;
    background:#ef4444;
    color:#fff;
    font-size:.65rem;
}

.dashboard-open-vehicle{
    display:flex;
    align-items:center;
    gap:4px;
    color:#1677e8;
    font-size:.75rem;
    font-weight:700;
}


/* SIDEBAR COLLAPSE */

@media(min-width:1024px){

    .sidebar-toggle{
        width:30px;
        height:30px;
        border-radius:8px;
        background:#f8fafc;
        color:#475569;
        border:1px solid #dbe3ed;
        margin-right:-4px;
    }

    .sidebar-toggle:hover{
        background:#eff6ff;
        color:#1677e8;
        border-color:#93c5fd;
    }

}


/* RESPONSIVE */

@media(max-width:1100px){

    .dashboard-sales-pipeline{
        grid-template-columns:1fr;
    }

    .dashboard-pipeline-arrow{
        display:none;
    }

    .dashboard-location-grid{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }

}

@media(max-width:800px){

    .dashboard-top-grid,
    .dashboard-process-grid,
    .dashboard-secondary-grid{
        grid-template-columns:1fr;
    }

    .dashboard-location-grid{
        grid-template-columns:1fr;
    }

    .dashboard-attention-row{
        grid-template-columns:1fr;
    }

    .dashboard-section-header{
        align-items:flex-start;
        flex-direction:column;
    }

}

.sidebar-toggle-expanded,
.sidebar-toggle-collapsed{
    font-size:22px;
    font-weight:700;
    line-height:1;
}

.sidebar-toggle-collapsed{display:none}

.sidebar-collapsed .sidebar-toggle-expanded{display:none}
.sidebar-collapsed .sidebar-toggle-collapsed{display:inline}

/* =========================================================
   DASHBOARD V2.1 - SECOND VISUAL PASS
   ========================================================= */

/* Prodajni proces dobiva veću vizualnu važnost */
.dashboard-sales{
    padding:18px;
    border-width:1px;
    box-shadow:0 7px 22px rgba(22,119,232,.07);
}

.dashboard-sale-stage{
    min-height:88px;
    padding:14px 15px;
}

.dashboard-sale-icon{
    width:32px;
    height:32px;
    border-radius:999px;
    background:rgba(255,255,255,.58);
}

.dashboard-sale-copy span{
    font-size:.78rem;
    font-weight:600;
}

.dashboard-sale-copy strong{
    font-size:1.75rem;
    margin-top:5px;
}

.dashboard-pipeline-arrow{
    font-size:1.35rem;
    font-weight:700;
}


/* Operativni sažetak */

.dashboard-action-strip{
    display:grid;
    grid-template-columns:minmax(155px,1.2fr) repeat(5,minmax(110px,1fr));
    gap:8px;
    align-items:stretch;
    margin:0 0 14px;
    padding:8px;
    background:#fff;
    border:1px solid #dfe7f0;
    border-radius:13px;
    box-shadow:0 4px 14px rgba(15,23,42,.04);
}

.dashboard-action-title{
    display:flex;
    align-items:center;
    gap:9px;
    padding:7px 10px;
}

.dashboard-action-title-icon{
    width:28px;
    height:28px;
    border-radius:999px;
    display:flex;
    align-items:center;
    justify-content:center;
    background:#10233d;
    color:#fff;
    font-weight:900;
}

.dashboard-action-title strong{
    display:block;
    font-size:.82rem;
}

.dashboard-action-title small{
    display:block;
    margin-top:1px;
    font-size:.68rem;
    color:#64748b;
}

.dashboard-action-item{
    min-height:52px;
    display:flex;
    align-items:center;
    gap:8px;
    padding:7px 9px;
    border-radius:9px;
    transition:transform .12s,filter .12s;
}

a.dashboard-action-item:hover{
    transform:translateY(-1px);
    filter:brightness(.985);
}

.dashboard-action-icon{
    width:29px;
    height:29px;
    border-radius:999px;
    display:flex;
    align-items:center;
    justify-content:center;
    flex:none;
    background:rgba(255,255,255,.72);
}

.dashboard-action-icon svg{
    width:16px;
    height:16px;
}

.dashboard-action-item>span:last-child{
    min-width:0;
}

.dashboard-action-item strong{
    display:block;
    font-size:1rem;
    line-height:1;
}

.dashboard-action-item small{
    display:block;
    margin-top:3px;
    font-size:.67rem;
    white-space:nowrap;
}

.dashboard-action-yellow{
    background:#fff7dc;
    color:#a85c00;
}

.dashboard-action-orange{
    background:#fff0e4;
    color:#c2410c;
}

.dashboard-action-blue{
    background:#eaf4ff;
    color:#1267c9;
}

.dashboard-action-red{
    background:#fff0f1;
    color:#dc2626;
}


/* Procesne kartice više se ne rastežu na istu visinu */

.dashboard-process-grid{
    align-items:start;
}

.dashboard-process-card{
    align-self:start;
}


/* Toggle na rub sidebara */

@media(min-width:1024px){

    .desktop-sidebar{
        overflow:visible;
    }

    .sidebar-toggle{
        position:absolute;
        top:92px;
        right:-13px;
        margin:0;
        z-index:5;
        box-shadow:0 2px 7px rgba(15,23,42,.16);
    }

    .sidebar-collapsed .sidebar-toggle{
        margin-right:0;
        right:-13px;
    }

}


/* Responsive */

@media(max-width:1250px){

    .dashboard-action-strip{
        grid-template-columns:repeat(3,minmax(0,1fr));
    }

    .dashboard-action-title{
        grid-column:1/-1;
    }

}

@media(max-width:700px){

    .dashboard-action-strip{
        grid-template-columns:1fr 1fr;
    }

    .dashboard-action-title{
        grid-column:1/-1;
    }

}

/* =========================================================
   DEPARTMENT CONTEXT REFINEMENT
   ========================================================= */

.dashboard-heading .department-context{
    min-width:215px;
    padding:8px 10px;
    gap:8px;
    border-radius:11px;
    background:#fff;
    border:1px solid #dfe7f0;
    box-shadow:0 3px 10px rgba(15,23,42,.035);
}

.dashboard-heading .department-context>svg{
    color:#1677e8;
    width:18px;
    height:18px;
}

.dashboard-heading .department-context label{
    flex:1;
    font-size:.68rem;
    color:#64748b;
}

.dashboard-heading .department-context .form-input{
    min-width:165px;
    margin-top:2px;
    padding:6px 28px 6px 9px;
    border:0;
    background:#f8fafc;
    font-size:.78rem;
    font-weight:700;
    color:#0f172a;
}

.dashboard-heading .department-context .form-input:focus{
    box-shadow:0 0 0 2px rgba(22,119,232,.15);
}

/* =========================================================
   DASHBOARD OPERATIONS - COMPACT HORIZONTAL LAYOUT
   ========================================================= */

.dashboard-operations{
    padding:16px;
    margin-bottom:14px;
}

.dashboard-operation-sections{
    display:flex;
    flex-direction:column;
}

.dashboard-operation{
    display:grid;
    grid-template-columns:170px minmax(0,1fr);
    gap:14px;
    align-items:center;
    padding:12px 0;
    border-top:1px solid #e8edf3;
}

.dashboard-operation:first-child{
    border-top:0;
    padding-top:3px;
}

.dashboard-operation:last-child{
    padding-bottom:3px;
}

.dashboard-operation-heading{
    display:flex;
    align-items:center;
    gap:9px;
}

.dashboard-operation-heading h3{
    font-weight:800;
    font-size:.84rem;
}

.dashboard-operation-heading small{
    display:block;
    margin-top:1px;
    color:#64748b;
    font-size:.65rem;
}

.dashboard-operation-icon{
    width:34px;
    height:34px;
    border-radius:9px;
    display:flex;
    align-items:center;
    justify-content:center;
    flex:none;
}

.dashboard-operation-icon svg{
    width:18px;
    height:18px;
}

.dashboard-operation-icon-cleaning{
    color:#1267c9;
    background:#eaf4ff;
}

.dashboard-operation-icon-repair{
    color:#b76a00;
    background:#fff5d8;
}

.dashboard-operation-icon-insurance{
    color:#15803d;
    background:#e8f8ed;
}

.dashboard-operation-statuses{
    display:flex;
    flex-wrap:wrap;
    gap:7px;
}

.dashboard-operation-status{
    min-width:125px;
    flex:1 1 125px;
    max-width:210px;
    min-height:44px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:8px;
    padding:7px 9px;
    border:1px solid #e2e8f0;
    border-radius:9px;
    background:#fbfdff;
}

.dashboard-operation-status:hover{
    border-color:#93c5fd;
    background:#f8fbff;
}

.dashboard-operation-status strong{
    color:#0f172a;
    font-size:.85rem;
}


/* Štete + ponude sada ne trebaju biti previsoke */

.dashboard-secondary-grid{
    align-items:stretch;
}

.dashboard-damage-card,
.dashboard-offer-card{
    min-height:0;
}

.dashboard-offer-value{
    min-height:105px;
}


/* responsive */

@media(max-width:900px){

    .dashboard-operation{
        grid-template-columns:1fr;
    }

    .dashboard-operation-status{
        max-width:none;
    }

}

/* =========================================================
   DASHBOARD DEPARTMENT SELECTOR - FINAL
   ========================================================= */

.dashboard-heading .department-context{
    min-width:190px;
    padding:0;
    gap:0;
    border:0;
    border-radius:0;
    background:transparent;
    box-shadow:none;
    align-items:flex-end;
}

/* Ikona nije potrebna u headeru */
.dashboard-heading .department-context>svg{
    display:none;
}

.dashboard-heading .department-context label{
    display:flex;
    flex-direction:column;
    align-items:flex-start;
    gap:4px;
    width:100%;
    color:#64748b;
    font-size:.62rem;
    font-weight:800;
    line-height:1;
    letter-spacing:.06em;
    text-transform:uppercase;
}

.dashboard-heading .department-context .form-input{
    width:100%;
    min-width:190px;
    height:38px;
    margin:0;
    padding:0 34px 0 12px;
    border:1px solid #dbe3ed;
    border-radius:9px;
    background:#fff;
    color:#0f172a;
    font-size:.78rem;
    font-weight:700;
    letter-spacing:0;
    text-transform:none;
    box-shadow:0 2px 6px rgba(15,23,42,.035);
}

.dashboard-heading .department-context .form-input:hover{
    border-color:#b8c6d8;
}

.dashboard-heading .department-context .form-input:focus{
    border-color:#60a5fa;
    box-shadow:0 0 0 3px rgba(59,130,246,.10);
}

@media(max-width:640px){
    .dashboard-heading .department-context{
        width:100%;
    }

    .dashboard-heading .department-context .form-input{
        width:100%;
    }
}

/* =========================================================
   DASHBOARD DEPARTMENT SELECTOR - HORIZONTAL CONTEXT PILL
   ========================================================= */

.dashboard-heading .department-context{
    display:flex;
    align-items:center;
    gap:9px;
    min-width:0;
    max-width:none;
    padding:6px 8px 6px 7px;
    background:#fff;
    border:1px solid #dbe5ef;
    border-radius:12px;
    box-shadow:0 3px 10px rgba(15,23,42,.045);
}

/* Vraćamo ikonu, ali kao mali naglasak */
.dashboard-heading .department-context>svg{
    display:block;
    width:30px;
    height:30px;
    padding:7px;
    flex:none;
    border-radius:8px;
    background:#eaf4ff;
    color:#1677e8;
}

/* Label i select stoje horizontalno */
.dashboard-heading .department-context label{
    width:auto;
    display:flex;
    flex-direction:row;
    align-items:center;
    gap:9px;
    color:#64748b;
    font-size:.74rem;
    font-weight:600;
    line-height:1;
    letter-spacing:0;
    text-transform:none;
    white-space:nowrap;
}

/* Mala razdjelnica između naziva i vrijednosti */
.dashboard-heading .department-context label::after{
    content:"";
    order:1;
    width:1px;
    height:22px;
    background:#e2e8f0;
}

/* Sam select više ne izgleda kao input unutar inputa */
.dashboard-heading .department-context .form-input{
    order:2;
    width:auto;
    min-width:155px;
    height:32px;
    margin:0;
    padding:0 30px 0 9px;
    border:0;
    border-radius:7px;
    background:#f8fafc;
    color:#0f172a;
    font-size:.78rem;
    font-weight:700;
    letter-spacing:0;
    text-transform:none;
    box-shadow:none;
    cursor:pointer;
}

.dashboard-heading .department-context .form-input:hover{
    background:#f1f5f9;
    border:0;
}

.dashboard-heading .department-context .form-input:focus{
    border:0;
    background:#eff6ff;
    box-shadow:0 0 0 2px rgba(22,119,232,.12);
}

/* Mobile */
@media(max-width:640px){

    .dashboard-heading .department-context{
        width:100%;
    }

    .dashboard-heading .department-context label{
        flex:1;
    }

    .dashboard-heading .department-context .form-input{
        flex:1;
        width:auto;
        min-width:0;
    }
}

/* Dashboard department selector - larger proportions */

.dashboard-heading .department-context{
    gap:12px;
    padding:9px 11px 9px 9px;
    border-radius:14px;
    min-height:58px;
}

.dashboard-heading .department-context>svg{
    width:38px;
    height:38px;
    padding:9px;
    border-radius:10px;
}

.dashboard-heading .department-context label{
    gap:12px;
    font-size:.82rem;
    font-weight:700;
}

.dashboard-heading .department-context label::after{
    height:28px;
}

.dashboard-heading .department-context .form-input{
    min-width:190px;
    height:38px;
    padding:0 34px 0 12px;
    border-radius:8px;
    font-size:.86rem;
    font-weight:700;
}

/* Dashboard - price integrity alert */

.dashboard-price-alert{
    margin-bottom:14px;
    border:1px solid #fecaca;
    border-left:5px solid #dc2626;
    border-radius:14px;
    background:linear-gradient(135deg,#fff,#fff7f7);
    box-shadow:0 5px 18px rgba(220,38,38,.08);
    overflow:hidden;
}

.dashboard-price-alert-head{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:16px;
    padding:14px 16px;
    border-bottom:1px solid #fee2e2;
}

.dashboard-price-alert-title{
    display:flex;
    align-items:center;
    gap:11px;
}

.dashboard-price-alert-title > div{
    display:flex;
    flex-direction:column;
    gap:2px;
}

.dashboard-price-alert-title strong{
    color:#991b1b;
    font-size:.95rem;
}

.dashboard-price-alert-title small{
    color:#64748b;
    font-size:.76rem;
}

.dashboard-price-alert-icon{
    display:flex;
    align-items:center;
    justify-content:center;
    width:30px;
    height:30px;
    flex:0 0 30px;
    border-radius:50%;
    background:#dc2626;
    color:#fff;
    font-size:1rem;
    font-weight:900;
}

.dashboard-price-alert-all{
    display:flex;
    align-items:center;
    gap:5px;
    color:#991b1b;
    font-size:.78rem;
    font-weight:800;
    text-decoration:none;
}

.dashboard-price-alert-all svg{
    width:14px;
    height:14px;
}

.dashboard-price-alert-items{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:0;
}

.dashboard-price-alert-item{
    display:flex;
    align-items:center;
    gap:10px;
    min-width:0;
    padding:13px 16px;
    color:#334155;
    text-decoration:none;
    border-right:1px solid #fee2e2;
    transition:background .15s ease;
}

.dashboard-price-alert-item:last-child{
    border-right:0;
}

.dashboard-price-alert-item:hover{
    background:#fff1f2;
}

.dashboard-price-alert-item > span:first-child{
    display:flex;
    flex:1;
    min-width:0;
    flex-direction:column;
    gap:2px;
}

.dashboard-price-alert-item strong{
    font-size:.82rem;
    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
}

.dashboard-price-alert-item small{
    color:#64748b;
    font-size:.7rem;
}

.dashboard-price-alert-count{
    display:flex;
    align-items:center;
    justify-content:center;
    min-width:32px;
    height:27px;
    padding:0 8px;
    border-radius:999px;
    background:#dc2626;
    color:#fff;
    font-size:.8rem;
    font-weight:900;
}

.dashboard-price-alert-item > svg{
    width:14px;
    height:14px;
    flex:0 0 auto;
    color:#94a3b8;
}


/* Dashboard - all prices valid */

.dashboard-price-ok{
    display:flex;
    align-items:center;
    gap:11px;
    margin-bottom:14px;
    padding:11px 15px;
    border:1px solid #bbf7d0;
    border-radius:12px;
    background:#f0fdf4;
}

.dashboard-price-ok-icon{
    display:flex;
    align-items:center;
    justify-content:center;
    width:27px;
    height:27px;
    flex:0 0 27px;
    border-radius:50%;
    background:#16a34a;
    color:#fff;
}

.dashboard-price-ok-icon svg{
    width:15px;
    height:15px;
}

.dashboard-price-ok > div{
    display:flex;
    flex:1;
    flex-direction:column;
    gap:1px;
}

.dashboard-price-ok strong{
    color:#166534;
    font-size:.82rem;
}

.dashboard-price-ok small{
    color:#64748b;
    font-size:.7rem;
}

.dashboard-price-ok > a{
    display:flex;
    align-items:center;
    gap:5px;
    color:#166534;
    font-size:.76rem;
    font-weight:800;
    text-decoration:none;
}

.dashboard-price-ok > a svg{
    width:14px;
    height:14px;
}

@media(max-width:900px){
    .dashboard-price-alert-items{
        grid-template-columns:1fr;
    }

    .dashboard-price-alert-item{
        border-right:0;
        border-bottom:1px solid #fee2e2;
    }

    .dashboard-price-alert-item:last-child{
        border-bottom:0;
    }
}

@media(max-width:640px){
    .dashboard-price-alert-head{
        align-items:flex-start;
    }

    .dashboard-price-alert-title small{
        display:none;
    }

    .dashboard-price-ok small{
        display:none;
    }
}


/* Partner sales availability control */
.sales-availability-control{
    display:flex;
    align-items:center;
    gap:10px;
    flex-wrap:wrap;
    margin-top:12px;
    padding:10px 12px;
    border:1px solid #e5e7eb;
    border-radius:12px;
    background:#f8fafc;
}

.sales-availability-control-label{
    font-size:13px;
    font-weight:700;
    color:#475569;
}

.sales-availability-control .form-input{
    width:auto;
    min-width:190px;
}

.sales-availability-control .btn{
    white-space:nowrap;
}

@media (max-width:640px){
    .sales-availability-control{
        align-items:stretch;
    }

    .sales-availability-control-label{
        width:100%;
    }

    .sales-availability-control .form-input{
        flex:1;
        width:auto;
        min-width:0;
    }
}

/* Reservation details */
.reservation-fields{
    margin-top:14px;
    padding-top:14px;
    border-top:1px solid #e5e7eb;
    display:grid;
    gap:12px;
}

.reservation-fields[hidden]{
    display:none !important;
}

.sales-availability-main{
    display:flex;
    align-items:end;
    gap:10px;
    flex-wrap:wrap;
}

.sales-availability-main label{
    flex:1;
    min-width:220px;
}

.sales-availability-main .form-input{
    width:100%;
}

.sales-availability-control{
    display:block;
}

.field-error{
    margin-top:8px;
    font-size:13px;
    font-weight:600;
    color:#b91c1c;
}

@media (max-width:640px){
    .sales-availability-main{
        align-items:stretch;
    }

    .sales-availability-main label,
    .sales-availability-main .btn{
        width:100%;
    }
}

/* Partner detail - sales status */
.partner-sale-status-card{
    margin-top:16px;
    padding:18px 20px;
    border:1px solid #e2e8f0;
    border-radius:14px;
    background:#fff;
}

.partner-sale-status-heading{
    display:flex;
    align-items:flex-start;
    justify-content:space-between;
    gap:16px;
    margin-bottom:16px;
}

.partner-sale-status-title{
    display:flex;
    align-items:center;
    gap:8px;
    font-size:16px;
    font-weight:700;
    color:#0f172a;
}

.partner-sale-status-title svg{
    width:20px;
    height:20px;
    color:#2563eb;
}

.partner-sale-status-help{
    margin-top:3px;
    font-size:13px;
    color:#64748b;
}

.partner-sale-status-actions{
    display:flex;
    align-items:flex-end;
    gap:10px;
}

.partner-sale-status-select{
    flex:1;
    max-width:360px;
}

.partner-sale-status-save{
    margin-bottom:0;
}

.partner-reservation-fields{
    display:grid;
    grid-template-columns:minmax(180px, 0.7fr) minmax(280px, 1.3fr);
    gap:14px;
    margin-top:16px;
    padding-top:16px;
    border-top:1px solid #e2e8f0;
}

.partner-reservation-fields[hidden]{
    display:none !important;
}

.partner-reservation-note textarea{
    resize:vertical;
}

.partner-reservation-meta{
    grid-column:1 / -1;
    font-size:12px;
    color:#64748b;
}

@media (max-width:640px){
    .partner-sale-status-card{
        padding:16px;
    }

    .partner-sale-status-heading{
        flex-direction:column;
        gap:8px;
    }

    .partner-sale-status-actions{
        flex-direction:column;
        align-items:stretch;
    }

    .partner-sale-status-select{
        max-width:none;
    }

    .partner-reservation-fields{
        grid-template-columns:1fr;
    }

    .partner-reservation-meta{
        grid-column:auto;
    }
}

/* =========================================================
   Partner detail - Actions section
   ========================================================= */

.partner-actions-section{
    margin-top:24px;
    padding-top:22px;
    border-top:1px solid #e2e8f0;
}

.partner-actions-header{
    display:flex;
    align-items:flex-start;
    justify-content:space-between;
    gap:16px;
    margin-bottom:12px;
}

.partner-actions-header h2{
    margin:0;
    font-size:20px;
    font-weight:700;
    color:#0f172a;
}

.partner-actions-header p{
    margin:3px 0 0;
    font-size:13px;
    color:#64748b;
}

.partner-action-item{
    padding:16px 18px;
    border:1px solid #e2e8f0;
    border-radius:12px;
    background:#fff;
}

.partner-action-description{
    display:flex;
    align-items:center;
    gap:12px;
    margin-bottom:14px;
}

.partner-action-icon{
    display:flex;
    align-items:center;
    justify-content:center;
    flex:0 0 38px;
    width:38px;
    height:38px;
    border-radius:10px;
    background:#eff6ff;
    color:#2563eb;
}

.partner-action-icon svg{
    width:20px;
    height:20px;
}

.partner-action-description h3{
    margin:0;
    font-size:15px;
    font-weight:700;
    color:#0f172a;
}

.partner-action-description p{
    margin:2px 0 0;
    font-size:13px;
    color:#64748b;
}

.partner-action-controls{
    display:flex;
    align-items:flex-end;
    gap:10px;
}

.partner-action-controls label{
    width:320px;
    max-width:100%;
}

.partner-action-controls .form-input{
    width:100%;
}

.partner-action-reservation{
    display:grid;
    grid-template-columns:190px minmax(260px, 1fr);
    gap:12px;
    margin-top:14px;
    padding:14px;
    border-radius:10px;
    background:#fffbeb;
    border:1px solid #fde68a;
}

.partner-action-reservation[hidden]{
    display:none !important;
}

.partner-action-reservation label{
    margin:0;
}

.partner-action-note{
    min-width:0;
}

.partner-action-meta{
    grid-column:1 / -1;
    font-size:12px;
    color:#64748b;
}

@media (max-width:640px){
    .partner-actions-section{
        margin-top:18px;
        padding-top:18px;
    }

    .partner-action-item{
        padding:14px;
    }

    .partner-action-controls{
        flex-direction:column;
        align-items:stretch;
    }

    .partner-action-controls label{
        width:100%;
    }

    .partner-action-controls .btn{
        width:100%;
    }

    .partner-action-reservation{
        grid-template-columns:1fr;
    }

    .partner-action-meta{
        grid-column:auto;
    }
}

/* ===== DAMAGE MODULE ===== */

.damage-card{
    overflow:hidden;
    border:1px solid #dbe3ed;
}

.damage-card-header{
    padding:18px 20px;
    background:#f8fafc;
    border-bottom:1px solid #e2e8f0;
}

.damage-section{
    margin-top:16px;
    border:1px solid #e2e8f0;
    border-left-width:4px;
    border-radius:14px;
    overflow:hidden;
    background:#fff;
}

.damage-section-header{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:12px;
    padding:12px 15px;
    border-bottom:1px solid rgba(148,163,184,.22);
}

.damage-section-title{
    display:flex;
    align-items:center;
    gap:9px;
    font-weight:800;
    font-size:.9rem;
}

.damage-section-body{
    padding:16px;
}

/* Šteta */
.damage-section-damage{
    border-color:#fecaca;
    border-left-color:#ef4444;
    background:#fffafa;
}
.damage-section-damage .damage-section-header{
    background:#fff1f2;
    color:#be123c;
}

/* Osiguranje */
.damage-section-insurance{
    border-color:#bfdbfe;
    border-left-color:#3b82f6;
    background:#fbfdff;
}
.damage-section-insurance .damage-section-header{
    background:#eff6ff;
    color:#1d4ed8;
}

/* Fotografije */
.damage-section-photos{
    border-color:#dbe3ed;
    border-left-color:#64748b;
}
.damage-section-photos .damage-section-header{
    background:#f8fafc;
    color:#475569;
}

/* Servis / ponude */
.damage-section-service{
    border-color:#fde68a;
    border-left-color:#f59e0b;
    background:#fffef8;
}
.damage-section-service .damage-section-header{
    background:#fffbeb;
    color:#b45309;
}

/* Administracija */
.damage-section-admin{
    border-color:#fecdd3;
    border-left-color:#e11d48;
    background:#fffafa;
}
.damage-section-admin .damage-section-header{
    background:#fff1f2;
    color:#be123c;
}

.damage-summary-grid{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:10px;
    margin-top:12px;
}

.damage-summary-item{
    padding:10px 12px;
    background:#fff;
    border:1px solid #e2e8f0;
    border-radius:10px;
}

.damage-summary-label{
    display:block;
    color:#64748b;
    font-size:.7rem;
    font-weight:700;
    text-transform:uppercase;
    letter-spacing:.035em;
    margin-bottom:3px;
}

.damage-summary-value{
    font-size:.88rem;
    font-weight:700;
    color:#1e293b;
}

.damage-actions-row{
    display:flex;
    flex-wrap:wrap;
    justify-content:flex-end;
    gap:8px;
    margin-top:14px;
}

.damage-new-card{
    border:2px dashed #bfdbfe;
    background:#f8fbff;
}

@media(max-width:767px){
    .damage-card-header,
    .damage-section-body{
        padding:14px;
    }

    .damage-summary-grid{
        grid-template-columns:1fr;
    }

    .damage-actions-row{
        justify-content:stretch;
    }

    .damage-actions-row .btn{
        flex:1;
    }
}

/* ===== COMPACT DOCUMENT UPLOAD ===== */

.document-upload-zone,
.document-upload-actions {
    min-height: 0 !important;
}

.document-upload-zone .btn,
.document-upload-actions .btn {
    width: auto !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 36px !important;
    padding: 8px 12px !important;
    align-self: center !important;
}

/*
 * Desna zona za dodavanje dokumenta ne smije izgledati
 * kao velika kartica/gumb.
 */
.documents-upload-button,
.document-add-button {
    width: auto !important;
    min-width: 0 !important;
    min-height: 36px !important;
    height: 36px !important;
    padding: 8px 12px !important;
}


/* ============================================================
   DAMAGE V3 - OFFER ACTIONS
   ============================================================ */

.offer-action-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-top: 12px;
}

.offer-action-row details {
    margin: 0 !important;
}

.offer-action-row form {
    margin: 0 !important;
}

.offer-action-row .btn {
    margin: 0 !important;
}


/* ============================================================
   DAMAGE V3 - COLLAPSIBLE DOCUMENTS
   ============================================================ */

.document-collapse {
    overflow: hidden;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: #fff;
}

.document-collapse-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    cursor: pointer;
    font-size: .85rem;
    font-weight: 700;
    color: #334155;
    background: #f8fafc;
    list-style: none;
}

.document-collapse-summary::-webkit-details-marker {
    display: none;
}

.document-collapse-summary::after {
    content: "⌄";
    margin-left: auto;
    font-size: 16px;
    color: #64748b;
    transition: transform .15s ease;
}

.document-collapse[open] > .document-collapse-summary::after {
    transform: rotate(180deg);
}

.document-collapse[open] > .document-collapse-summary {
    border-bottom: 1px solid #e2e8f0;
}

.document-collapse-body {
    padding: 12px;
}

@media(max-width:767px) {
    .offer-action-row {
        align-items: stretch;
    }
}


/* ============================================================
   DAMAGE V3 - EDIT ACTIONS IN HEADERS
   ============================================================ */

.btn-compact {
    min-height: 32px !important;
    height: 32px;
    padding: 5px 10px !important;
    font-size: .78rem;
    white-space: nowrap;
}

.section-edit-hidden-summary {
    display: none;
}

.section-edit-details {
    margin-top: 14px;
}

.section-edit-details:not([open]) {
    margin-top: 0;
}


/* ============================================================
   DAMAGE V3 - INDIVIDUAL OFFER CARDS
   ============================================================ */

.damage-offer-card {
    position: relative;
    margin-bottom: 14px;
    padding: 15px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 1px 3px rgba(15, 23, 42, .04);
}

.damage-offer-card:last-of-type {
    margin-bottom: 0;
}

/* Odabrana ponuda dobiva diskretan naglasak */
.damage-offer-card-selected {
    border-color: #86efac;
    background: #fafffc;
    box-shadow: 0 0 0 1px rgba(34, 197, 94, .06);
}

/*
 * Dokumenti su već vlastiti collapsible blok.
 * Unutar kartice ih malo vizualno odvajamo.
 */
.damage-offer-card .document-collapse {
    margin-top: 14px;
}

/*
 * Forma za uređivanje otvorena unutar iste kartice.
 */
.damage-offer-card .section-edit-details[open] {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid #e2e8f0;
}

/*
 * Operativne akcije ostaju kompaktne.
 */
.damage-offer-card .offer-action-row {
    padding-top: 2px;
}

@media(max-width:767px) {
    .damage-offer-card {
        padding: 12px;
    }
}


/* ============================================================
   DAMAGE V3 - OFFER EDIT FORM
   ============================================================ */

.offer-edit-grid {
    display: grid;
    grid-template-columns:
        minmax(190px, 1.4fr)
        minmax(130px, .7fr)
        minmax(170px, .8fr)
        minmax(190px, 1fr);
    gap: 12px;
    align-items: end;
}

/* Napomena preko cijele širine */
.offer-edit-grid > label:nth-of-type(5) {
    grid-column: 1 / -1;
}

/* Red s tipkom Spremi */
.offer-edit-grid > .md\:col-span-2,
.offer-edit-grid > div:last-child {
    grid-column: 1 / -1;
    display: flex;
    justify-content: flex-end;
}

/* Forma više ne treba nepotrebno široku tipku */
.offer-edit-grid .btn-save {
    width: auto;
}

/* Tablet */
@media(max-width:1100px) {
    .offer-edit-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .offer-edit-grid > label:nth-of-type(5) {
        grid-column: 1 / -1;
    }
}

/* Mobitel */
@media(max-width:767px) {
    .offer-edit-grid {
        grid-template-columns: 1fr;
    }

    .offer-edit-grid > label:nth-of-type(5),
    .offer-edit-grid > .md\:col-span-2,
    .offer-edit-grid > div:last-child {
        grid-column: 1;
    }
}


/* ===== OFFER EDIT FINAL ALIGNMENT ===== */

.offer-edit-grid > label:nth-of-type(5) {
    grid-column: 1 / -1 !important;
    width: 100%;
    margin-left: 0 !important;
}

.offer-edit-grid > label:nth-of-type(5) .form-input {
    display: block;
    width: 100%;
    margin-left: 0 !important;
}

.offer-edit-grid > div:last-child {
    grid-column: 1 / -1 !important;
    width: 100%;
    display: flex;
    justify-content: flex-end;
    margin-top: 2px;
}


/* ============================================================
   DAMAGE V3 - OFFER FORM FINAL LAYOUT
   ============================================================ */

.offer-edit-grid {
    display: grid !important;
    grid-template-columns:
        minmax(240px, 1.4fr)
        minmax(130px, .7fr)
        minmax(180px, .8fr)
        minmax(200px, 1fr) !important;
    gap: 12px !important;
    width: 100% !important;
    align-items: end;
}

.offer-edit-grid > label {
    min-width: 0;
    width: 100%;
}

.offer-edit-grid > label .form-input {
    width: 100%;
}

/* Napomena zauzima CIJELU širinu kartice */
.offer-edit-grid > .offer-edit-note {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    margin: 0 !important;
}

/* Spremanje također ima cijeli red, tipka desno */
.offer-edit-grid > .offer-edit-submit {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    display: flex !important;
    justify-content: flex-end !important;
    align-items: center;
    margin: 0 !important;
}

/* Više ne primjenjuj stara nth-of-type pravila */
.offer-edit-grid > label:nth-of-type(5) {
    grid-column: auto;
}

@media(max-width:1100px) {
    .offer-edit-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }

    .offer-edit-grid > .offer-edit-note,
    .offer-edit-grid > .offer-edit-submit {
        grid-column: 1 / -1 !important;
    }
}

@media(max-width:767px) {
    .offer-edit-grid {
        grid-template-columns: 1fr !important;
    }

    .offer-edit-grid > .offer-edit-note,
    .offer-edit-grid > .offer-edit-submit {
        grid-column: 1 !important;
    }
}


/* ============================================================
   DAMAGE V3 - OFFER EDIT FULL WIDTH FIX
   ============================================================ */

/*
 * offer-action-row sadrži details forme i akcije.
 * Kada je forma otvorena, details mora prijeći u novi red
 * i zauzeti cijelu širinu kartice.
 */
.damage-offer-card .offer-action-row {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
}

.damage-offer-card .offer-action-row > .section-edit-details {
    flex: 0 0 100%;
    width: 100%;
    max-width: none;
    order: 10;
}

/*
 * Dok je zatvoren nema vidljivog sadržaja niti zauzima prostor.
 */
.damage-offer-card .offer-action-row > .section-edit-details:not([open]) {
    flex-basis: 0;
    width: 0;
    margin: 0 !important;
    padding: 0 !important;
}

/*
 * Otvorena forma koristi cijelu karticu.
 */
.damage-offer-card .offer-action-row > .section-edit-details[open] {
    flex: 0 0 100%;
    width: 100% !important;
    max-width: none !important;
    margin-top: 14px !important;
    padding-top: 14px;
    border-top: 1px solid #e2e8f0;
}

.damage-offer-card .offer-action-row > .section-edit-details[open] > form {
    width: 100% !important;
    max-width: none !important;
}

/*
 * Četiri gornja polja koriste kompletnu raspoloživu širinu.
 */
.damage-offer-card .offer-edit-grid {
    width: 100% !important;
    max-width: none !important;
    grid-template-columns:
        minmax(0, 1.4fr)
        minmax(0, .7fr)
        minmax(0, .8fr)
        minmax(0, 1fr) !important;
}

/* Napomena cijelim redom */
.damage-offer-card .offer-edit-note {
    grid-column: 1 / -1 !important;
    width: 100% !important;
}

/* Spremanje desno, također cijeli red */
.damage-offer-card .offer-edit-submit {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    display: flex !important;
    justify-content: flex-end !important;
}



/* ==========================================================
   DASHBOARD V2
   ========================================================== */

.dashboard-v2-top{
    display:grid;
    grid-template-columns:1fr 1fr 1fr;
    gap:14px;
    margin-bottom:16px;
}

.dashboard-v2-stat{
    display:flex;
    align-items:center;
    gap:14px;
    min-height:92px;
    padding:16px 18px;
    text-decoration:none;
    color:inherit;
    transition:.15s ease;
}

.dashboard-v2-stat:hover{
    transform:translateY(-1px);
    box-shadow:0 8px 22px rgba(15,23,42,.07);
}

.dashboard-v2-stat-icon{
    width:42px;
    height:42px;
    border-radius:50%;
    display:flex;
    align-items:center;
    justify-content:center;
    flex:0 0 42px;
}

.dashboard-v2-stat-icon svg{
    width:19px;
    height:19px;
}

.dashboard-v2-icon-blue{
    background:#eaf4ff;
    color:#1670d2;
}

.dashboard-v2-icon-yellow{
    background:#fff5d6;
    color:#d58a00;
}

.dashboard-v2-icon-orange{
    background:#fff0d9;
    color:#d97706;
}

.dashboard-v2-stat-copy{
    flex:1;
    min-width:0;
}

.dashboard-v2-stat-copy small,
.dashboard-v2-requests-head small{
    display:block;
    color:#64748b;
    font-size:12px;
    font-weight:700;
}

.dashboard-v2-stat-copy strong,
.dashboard-v2-requests-head strong{
    display:block;
    color:#0f172a;
    font-size:27px;
    line-height:1.05;
    margin-top:4px;
}

.dashboard-v2-chevron{
    color:#94a3b8;
}

.dashboard-v2-requests{
    padding:0;
    overflow:hidden;
}

.dashboard-v2-requests-head{
    display:flex;
    align-items:center;
    gap:12px;
    padding:12px 16px 10px;
}

.dashboard-v2-request-links{
    border-top:1px solid #e8edf3;
}

.dashboard-v2-request-links a{
    display:grid;
    grid-template-columns:1fr auto auto;
    align-items:center;
    gap:10px;
    padding:7px 16px;
    color:inherit;
    text-decoration:none;
}

.dashboard-v2-request-links a+a{
    border-top:1px solid #eef2f6;
}

.dashboard-v2-request-links span{
    font-size:12px;
    font-weight:700;
}

.dashboard-v2-request-links strong{
    font-size:15px;
}

.dashboard-v2-request-links svg{
    width:14px;
    color:#94a3b8;
}


.dashboard-v2-section{
    padding:18px;
    margin-bottom:16px;
}

.dashboard-v2-section-head{
    display:flex;
    align-items:flex-start;
    justify-content:space-between;
    gap:18px;
    margin-bottom:16px;
}

.dashboard-v2-section-head h2{
    display:flex;
    align-items:center;
    gap:7px;
    margin:2px 0 2px;
    font-size:16px;
    font-weight:800;
    color:#172033;
}

.dashboard-v2-section-head p{
    margin:0;
    color:#718096;
    font-size:12px;
}

.dashboard-v2-eyebrow{
    display:block;
    font-size:9px;
    font-weight:800;
    letter-spacing:.12em;
    color:#94a3b8;
    margin-bottom:2px;
}


.dashboard-v2-processes{
    display:grid;
    gap:0;
    border:1px solid #e7edf4;
    border-radius:12px;
    overflow:hidden;
}

.dashboard-v2-process{
    display:grid;
    grid-template-columns:205px 1fr;
    gap:16px;
    align-items:center;
    padding:13px 14px;
    background:#fff;
}

.dashboard-v2-process+.dashboard-v2-process{
    border-top:1px solid #e7edf4;
}

.dashboard-v2-process-title{
    display:flex;
    align-items:center;
    gap:10px;
    min-width:0;
}

.dashboard-v2-process-title>div{
    min-width:0;
}

.dashboard-v2-process-title h3{
    margin:0;
    font-size:13px;
    font-weight:800;
}

.dashboard-v2-process-title small{
    display:block;
    color:#94a3b8;
    font-size:10px;
    margin-top:1px;
}

.dashboard-v2-process-icon{
    width:32px;
    height:32px;
    border-radius:9px;
    display:flex;
    align-items:center;
    justify-content:center;
    flex:0 0 32px;
}

.dashboard-v2-process-icon svg{
    width:16px;
    height:16px;
}

.dashboard-v2-process-cleaning{
    background:#eaf4ff;
    color:#1670d2;
}

.dashboard-v2-process-repair{
    background:#fff4d9;
    color:#c77900;
}

.dashboard-v2-process-insurance{
    background:#e8f8ee;
    color:#15803d;
}

.dashboard-v2-todo{
    display:none;
}

.dashboard-v2-status-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(125px,1fr));
    gap:6px;
}

.dashboard-v2-status-grid a{
    min-height:40px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:8px;
    padding:6px 9px;
    border:1px solid #e7edf4;
    border-radius:8px;
    text-decoration:none;
    color:inherit;
    background:#fbfdff;
}

.dashboard-v2-status-grid a:hover{
    border-color:#bfd3e8;
    background:#f8fbff;
}

.dashboard-v2-status-grid strong{
    font-size:13px;
    color:#172033;
}


.dashboard-v2-sales{
    border-color:#dbe7f5;
}

.dashboard-v2-sales-body{
    display:grid;
    grid-template-columns:minmax(0,1fr) 280px;
    gap:14px;
    align-items:stretch;
}

.dashboard-v2-pipeline{
    height:100%;
    display:grid;
    grid-template-columns:1fr auto 1fr auto 1fr;
    align-items:center;
    gap:8px;
}

.dashboard-v2-stage{
    min-height:88px;
    border-radius:11px;
    display:flex;
    align-items:center;
    gap:12px;
    padding:14px;
    text-decoration:none;
    transition:.15s ease;
}

.dashboard-v2-stage:hover{
    transform:translateY(-1px);
}

.dashboard-v2-stage>span{
    width:32px;
    height:32px;
    border-radius:50%;
    display:flex;
    align-items:center;
    justify-content:center;
    background:rgba(255,255,255,.7);
}

.dashboard-v2-stage>span svg{
    width:16px;
    height:16px;
}

.dashboard-v2-stage div small{
    display:block;
    font-size:11px;
    font-weight:800;
}

.dashboard-v2-stage div strong{
    display:block;
    font-size:25px;
    line-height:1;
    margin-top:5px;
}

.dashboard-v2-stage-yellow{
    background:#fff5d9;
    color:#b76a00;
}

.dashboard-v2-stage-green{
    background:#e8f8ee;
    color:#15803d;
}

.dashboard-v2-stage-red{
    background:#fff0f1;
    color:#dc2626;
}

.dashboard-v2-stage-blue{
    background:#eaf4ff;
    color:#1267c9;
}

.dashboard-v2-stage-arrow{
    color:#94a3b8;
    font-size:18px;
}

.dashboard-v2-sales-alerts{
    display:grid;
    gap:8px;
}

.dashboard-v2-sales-alert{
    display:grid;
    grid-template-columns:32px 1fr auto;
    gap:9px;
    align-items:center;
    padding:9px 10px;
    border:1px solid #e7edf4;
    border-radius:10px;
    color:inherit;
    text-decoration:none;
}

.dashboard-v2-sales-alert-icon{
    width:30px;
    height:30px;
    border-radius:50%;
    display:flex;
    align-items:center;
    justify-content:center;
}

.dashboard-v2-sales-alert-icon svg{
    width:15px;
    height:15px;
}

.dashboard-v2-sales-alert span:nth-child(2) small{
    display:block;
    color:#64748b;
    font-size:9px;
    font-weight:800;
    text-transform:uppercase;
    letter-spacing:.05em;
}

.dashboard-v2-sales-alert span:nth-child(2) strong{
    display:block;
    font-size:15px;
    line-height:1.15;
}

.dashboard-v2-sales-alert span:nth-child(2) b{
    display:block;
    font-size:9px;
    color:#94a3b8;
    font-weight:600;
    margin-top:2px;
}

.dashboard-v2-sales-alert>svg{
    width:14px;
    color:#94a3b8;
}

.dashboard-v2-sales-alert.is-danger{
    background:#fff7f7;
    border-color:#fecaca;
}

.dashboard-v2-sales-alert.is-danger .dashboard-v2-sales-alert-icon{
    background:#fee2e2;
    color:#dc2626;
}

.dashboard-v2-sales-alert.is-ok{
    background:#f4fbf6;
    border-color:#ccebd5;
}

.dashboard-v2-sales-alert.is-ok .dashboard-v2-sales-alert-icon{
    background:#dcfce7;
    color:#15803d;
}

.dashboard-v2-sales-alert.is-neutral .dashboard-v2-sales-alert-icon{
    background:#eef4fb;
    color:#64748b;
}

.dashboard-v2-price-details{
    margin-top:12px;
    border:1px solid #fecaca;
    border-radius:10px;
    overflow:hidden;
    background:#fffafa;
}

.dashboard-v2-price-details summary{
    display:flex;
    justify-content:space-between;
    align-items:center;
    padding:9px 12px;
    cursor:pointer;
    color:#991b1b;
    font-size:11px;
    font-weight:800;
}

.dashboard-v2-price-details summary span{
    background:#dc2626;
    color:#fff;
    border-radius:999px;
    min-width:21px;
    height:21px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
}

.dashboard-v2-price-details>div{
    border-top:1px solid #fecaca;
}

.dashboard-v2-price-details a{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:15px;
    padding:8px 12px;
    text-decoration:none;
    color:inherit;
}

.dashboard-v2-price-details a+a{
    border-top:1px solid #fee2e2;
}

.dashboard-v2-price-details a span strong{
    display:block;
    font-size:11px;
}

.dashboard-v2-price-details a span small{
    display:block;
    font-size:9px;
    color:#94a3b8;
}

.dashboard-v2-price-details a>b{
    color:#dc2626;
}


.dashboard-v2-secondary{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:14px;
    margin-bottom:16px;
}

.dashboard-v2-damage{
    padding:18px;
    border-color:#fecaca;
}

.dashboard-v2-damage .dashboard-v2-section-head{
    margin-bottom:10px;
}

.dashboard-v2-damage-list{
    display:grid;
    gap:5px;
}

.dashboard-v2-damage-list a{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:10px;
    padding:7px 9px;
    border:1px solid #e7edf4;
    border-radius:7px;
    text-decoration:none;
    color:inherit;
    font-size:11px;
}

.dashboard-v2-offers{
    display:grid;
    grid-template-columns:auto 1fr auto;
    align-items:center;
    gap:16px;
    padding:20px;
    text-decoration:none;
    color:inherit;
    border-color:#cfe2fb;
}

.dashboard-v2-offers-icon{
    width:50px;
    height:50px;
    border-radius:50%;
    display:flex;
    align-items:center;
    justify-content:center;
    background:#eaf4ff;
    color:#1670d2;
}

.dashboard-v2-offers div>small{
    display:block;
    color:#94a3b8;
    font-size:9px;
    font-weight:800;
    letter-spacing:.1em;
}

.dashboard-v2-offers h2{
    margin:2px 0 6px;
    font-size:14px;
}

.dashboard-v2-offers strong{
    font-size:27px;
    line-height:1;
}

.dashboard-v2-offers p{
    display:inline;
    margin-left:5px;
    color:#64748b;
    font-size:11px;
}


.dashboard-v2-locations{
    display:grid;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:8px;
}

.dashboard-v2-locations>a{
    display:grid;
    grid-template-columns:auto 1fr auto;
    align-items:center;
    gap:9px;
    min-height:60px;
    padding:9px 11px;
    border:1px solid #e7edf4;
    border-radius:9px;
    text-decoration:none;
    color:inherit;
    background:#fbfdff;
}

.dashboard-v2-location-icon{
    width:30px;
    height:30px;
    border-radius:8px;
    display:flex;
    align-items:center;
    justify-content:center;
    background:#eaf4ff;
    color:#1670d2;
}

.dashboard-v2-locations>a>span:nth-child(2) small{
    display:block;
    font-size:10px;
    color:#64748b;
    font-weight:700;
}

.dashboard-v2-locations>a>span:nth-child(2) strong{
    font-size:18px;
    margin-right:4px;
}

.dashboard-v2-locations>a>span:nth-child(2) b{
    color:#94a3b8;
    font-size:9px;
    font-weight:600;
}

.dashboard-v2-locations>a>svg{
    width:13px;
    color:#94a3b8;
}


.dashboard-v2-attention{
    padding:18px;
    border-color:#fecaca;
}

.dashboard-v2-attention .dashboard-v2-section-head{
    margin-bottom:10px;
}

.dashboard-v2-attention-icon{
    width:19px;
    height:19px;
    border-radius:50%;
    background:#fee2e2;
    color:#dc2626;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    font-size:11px;
    font-weight:900;
}

.dashboard-v2-attention-count{
    min-width:28px;
    height:28px;
    padding:0 8px;
    border-radius:999px;
    display:flex;
    align-items:center;
    justify-content:center;
    background:#fee2e2;
    color:#dc2626;
    font-size:12px;
    font-weight:800;
}

.dashboard-v2-attention-list{
    display:grid;
    gap:4px;
}

.dashboard-v2-attention-row{
    display:grid;
    grid-template-columns:260px 1fr auto;
    gap:12px;
    align-items:center;
    min-height:34px;
    padding:5px 8px;
    background:#fff8f8;
    border-radius:6px;
}

.dashboard-v2-attention-vehicle a{
    color:#334155;
    font-size:11px;
    font-weight:800;
    text-decoration:underline;
}

.dashboard-v2-attention-message{
    font-size:10px;
    color:#dc2626;
}

.dashboard-v2-attention-message b{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    width:15px;
    height:15px;
    margin-right:5px;
    border-radius:50%;
    color:#fff;
    background:#ef4444;
    font-size:9px;
}

.dashboard-v2-open{
    display:flex;
    align-items:center;
    gap:3px;
    font-size:10px;
    font-weight:800;
    color:#1670d2;
    text-decoration:none;
}

.dashboard-v2-open svg{
    width:12px;
}

.dashboard-v2-empty{
    display:flex;
    align-items:center;
    gap:8px;
    padding:10px;
    border-radius:8px;
    background:#f4fbf6;
    color:#15803d;
    font-size:11px;
    font-weight:700;
}


@media(max-width:1100px){

    .dashboard-v2-top{
        grid-template-columns:1fr 1fr;
    }

    .dashboard-v2-sales-body{
        grid-template-columns:1fr;
    }

    .dashboard-v2-locations{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }

}

@media(max-width:760px){

    .dashboard-v2-top,
    .dashboard-v2-secondary{
        grid-template-columns:1fr;
    }

    .dashboard-v2-process{
        grid-template-columns:1fr;
    }

    .dashboard-v2-pipeline{
        grid-template-columns:1fr;
    }

    .dashboard-v2-stage-arrow{
        display:none;
    }

    .dashboard-v2-locations{
        grid-template-columns:1fr;
    }

    .dashboard-v2-attention-row{
        grid-template-columns:1fr;
    }

    .dashboard-v2-section-head{
        flex-direction:column;
    }

}


/* ==========================================================
   DASHBOARD V2 — SALES SUMMARY
   ========================================================== */

.dashboard-v2-icon-green{
    background:#e8f8ee;
    color:#15803d;
}

.dashboard-v2-sold{
    margin-top:14px;
    padding-top:14px;
    border-top:1px solid #e7edf4;
}

.dashboard-v2-sold-heading{
    display:flex;
    align-items:flex-end;
    justify-content:space-between;
    gap:12px;
    margin-bottom:9px;
}

.dashboard-v2-sold-heading h3{
    margin:1px 0 0;
    font-size:13px;
    font-weight:800;
    color:#172033;
}

.dashboard-v2-sold-heading>small{
    color:#94a3b8;
    font-size:10px;
    font-weight:800;
}

.dashboard-v2-sold-grid{
    display:grid;
    grid-template-columns:1fr 1fr 1.45fr;
    gap:8px;
}

.dashboard-v2-sold-stat{
    display:flex;
    align-items:center;
    gap:10px;
    min-height:68px;
    padding:10px 12px;
    border:1px solid #dce8df;
    border-radius:9px;
    background:#f8fcf9;
}

.dashboard-v2-sold-icon{
    width:32px;
    height:32px;
    border-radius:50%;
    display:flex;
    align-items:center;
    justify-content:center;
    flex:0 0 32px;
    background:#dcfce7;
    color:#15803d;
}

.dashboard-v2-sold-icon svg{
    width:15px;
    height:15px;
}

.dashboard-v2-sold-stat>span:last-child{
    min-width:0;
}

.dashboard-v2-sold-stat small{
    display:block;
    color:#64748b;
    font-size:9px;
    font-weight:800;
    text-transform:uppercase;
    letter-spacing:.04em;
}

.dashboard-v2-sold-stat strong{
    display:inline-block;
    margin-top:2px;
    color:#166534;
    font-size:20px;
    line-height:1.1;
}

.dashboard-v2-sold-stat b{
    margin-left:3px;
    color:#94a3b8;
    font-size:9px;
    font-weight:600;
}

.dashboard-v2-sold-value strong{
    font-size:18px;
}

.dashboard-v2-sold-value b{
    display:block;
    margin:2px 0 0;
}

@media(max-width:760px){
    .dashboard-v2-sold-grid{
        grid-template-columns:1fr;
    }
}
