:root {
    --acc-bg: #f6f8fb;
    --acc-border: #eaeef4;
    --acc-primary: #4f46e5;
    --acc-primary-soft: #eef2ff;
    --acc-text: #1f2937;
    --acc-muted: #6b7280;
}

body {
    background: var(--acc-bg);
    color: var(--acc-text);
    font-family: 'Red Hat Text', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
h1, h2, h3, h4, h5, h6, .fw-bold, .fw-semibold, .acc-stat-num {
    font-family: 'Red Hat Display', system-ui, sans-serif;
}

/* ---------- Lucide ikone ---------- */
[data-lucide] { width: 20px; height: 20px; stroke-width: 2; vertical-align: -3px; }

/* ---------- Linkovi: bez podcrtavanja, podebljani ---------- */
a { text-decoration: none; }
a:hover, a:focus { text-decoration: none; }
/* tekstualni linkovi (ne gumbi/navigacija) su podebljani umjesto podcrtani */
a:not(.btn):not(.nav-link):not(.dropdown-item):not(.list-group-item):not(.navbar-brand) {
    font-weight: 600;
}

/* ---------- Gumbi (veliki, moderni, blago zaobljeni) ---------- */
.btn {
    border-radius: 10px;
    font-weight: 600;
    padding: .6rem 1.15rem;
    display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
}
.btn [data-lucide] { width: 18px; height: 18px; }
.btn-lg { padding: .85rem 1.5rem; font-size: 1rem; border-radius: 12px; }
.btn-sm { padding: .4rem .7rem; border-radius: 9px; }
.form-control, .form-select { border-radius: 10px; }
.form-control-lg, .form-select-lg { border-radius: 12px; }

/* ---------- Auth ---------- */
.auth-wrap {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: linear-gradient(160deg, #eef2ff 0%, #f6f8fb 60%);
}
.auth-card {
    width: 100%;
    max-width: 400px;
    background: #fff;
    border-radius: 18px;
    padding: 2rem;
    box-shadow: 0 10px 40px rgba(79, 70, 229, .10);
}
.auth-divider { text-align: center; margin: 1.25rem 0; color: #adb5bd; }

/* ---------- Sidebar (svijetli) ---------- */
.acc-sidebar {
    width: 260px;
    background: #fff;
    color: var(--acc-text);
    min-height: 100vh;
    border-right: 1px solid var(--acc-border);
}
@media (min-width: 992px) {
    .acc-sidebar { position: sticky; top: 0; display: flex; flex-direction: column; }
}
.acc-brand {
    align-items: center; gap: .75rem;
    padding: 1.15rem 1.25rem;
    color: var(--acc-text);
    border-bottom: 1px solid var(--acc-border);
}
.acc-brand i { font-size: 1.5rem; color: var(--acc-primary); }
.acc-menu { padding: .5rem; flex-grow: 1; list-style: none; margin: 0; }
.acc-menu li { margin-bottom: 2px; }
.acc-menu .nav-link {
    color: var(--acc-muted); padding: .65rem .85rem;
    display: flex; align-items: center; gap: .65rem;
    border-radius: 10px;
    font-weight: 500;
    transition: background .15s, color .15s;
}
.acc-menu .nav-link [data-lucide] { width: 20px; height: 20px; flex-shrink: 0; }
.acc-menu .nav-link:hover { color: var(--acc-text); background: var(--acc-bg); }
.acc-menu .nav-link.active { color: var(--acc-primary); background: var(--acc-primary-soft); }

/* ---------- Sidebar submenu ---------- */
.acc-submenu { list-style: none; margin: 2px 0 0; padding: 0 0 0 1.6rem; display: none; }
.acc-has-sub.open .acc-submenu { display: block; }
.acc-submenu .nav-link { font-size: .92rem; padding: .5rem .85rem; }
.acc-sub-arrow { margin-left: auto; width: 16px !important; height: 16px !important; transition: transform .2s; }
.acc-has-sub.open > .nav-link .acc-sub-arrow { transform: rotate(90deg); }

/* ---------- Okrugli icon gumbi (topbar) ---------- */
.acc-icon-btn {
    width: 40px; height: 40px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    background: #fff; border: 1px solid var(--acc-border); color: var(--acc-text);
    position: relative; text-decoration: none; transition: background .15s, border-color .15s;
}
.acc-icon-btn:hover { background: var(--acc-bg); border-color: #d7dce6; color: var(--acc-text); }
.acc-icon-btn.active { background: var(--acc-primary-soft); border-color: #dfe3fb; color: var(--acc-primary); }
.acc-icon-btn [data-lucide] { width: 19px; height: 19px; }
.acc-icon-btn-wide { width: auto; padding: 0 .8rem; gap: .35rem; border-radius: 20px; }
.acc-badge {
    position: absolute; top: -4px; right: -4px;
    min-width: 18px; height: 18px; padding: 0 4px;
    border-radius: 9px; background: #dc2626; color: #fff;
    font-size: .68rem; font-weight: 700; line-height: 18px; text-align: center;
    border: 2px solid #fff;
}

/* ---------- Topbar ---------- */
.acc-main { min-width: 0; }
.acc-topbar {
    display: flex; align-items: center; gap: .75rem;
    background: rgba(255, 255, 255, .85);
    backdrop-filter: blur(8px);
    padding: .65rem 1rem;
    border-bottom: 1px solid var(--acc-border);
    position: sticky; top: 0; z-index: 10;
}
.acc-page-title { font-weight: 700; }
.acc-avatar {
    width: 32px; height: 32px; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--acc-primary); color: #fff; font-weight: 600; font-size: .85rem;
}
.acc-content { padding: 1.5rem; }

/* ---------- Cards / stats ---------- */
.acc-card {
    border: 1px solid var(--acc-border);
    border-radius: 14px;
    box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
}
.acc-card .card-header {
    background: transparent;
    border-bottom: 1px solid var(--acc-border);
    font-weight: 600;
}
.acc-stat {
    background: #fff; border: 1px solid var(--acc-border); border-radius: 14px;
    padding: 1.15rem 1.25rem; display: flex; gap: 1rem; align-items: center;
    height: 100%; min-height: 96px;
    box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
    transition: transform .15s, box-shadow .15s;
}
.acc-stat:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(16, 24, 40, .08); }
.acc-stat > div { min-width: 0; }
.acc-stat-icon {
    width: 48px; height: 48px; border-radius: 12px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 1.35rem; flex-shrink: 0;
}
.acc-stat-num { font-size: 1.65rem; font-weight: 700; line-height: 1; }
.acc-stat-label { font-size: .82rem; color: var(--acc-muted); margin-top: .25rem; line-height: 1.2; }

.stat-soft-primary { background: #eef2ff; color: #4f46e5; }
.stat-soft-success { background: #ecfdf5; color: #059669; }
.stat-soft-warning { background: #fff7ed; color: #d97706; }
.stat-soft-danger  { background: #fef2f2; color: #dc2626; }

.acc-prose { line-height: 1.7; }
.acc-notif-menu { min-width: 300px; border: 1px solid var(--acc-border); border-radius: 14px; box-shadow: 0 10px 30px rgba(16, 24, 40, .12); }
.acc-notif-list { max-height: 320px; overflow: auto; }
.acc-notif-dot { width: 10px; height: 10px; border-radius: 50%; margin-top: .35rem; flex-shrink: 0; }

/* ---------- Gumbi ---------- */
.btn-primary { background: var(--acc-primary); border-color: var(--acc-primary); }
.btn-primary:hover { background: #4338ca; border-color: #4338ca; }

/* ---------- Narudzbe (siri, pregledni redci) ---------- */
.acc-orders { display: flex; flex-direction: column; gap: .85rem; }
.acc-order-card {
    background: #fff; border: 1px solid var(--acc-border); border-radius: 14px;
    padding: 1rem 1.35rem;
    height: 86px;
    display: flex; align-items: center; justify-content: space-between; gap: 1.25rem;
    box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
    transition: box-shadow .15s, transform .15s;
    overflow: hidden;
}
.acc-order-card:hover { box-shadow: 0 6px 18px rgba(16, 24, 40, .08); transform: translateY(-1px); }
.acc-order-main { display: flex; align-items: center; gap: 1rem; min-width: 0; }
.acc-order-icon {
    width: 48px; height: 48px; border-radius: 12px; flex-shrink: 0;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--acc-primary-soft); color: var(--acc-primary);
}
.acc-order-icon [data-lucide] { width: 24px; height: 24px; }
.acc-order-info { min-width: 0; }
.acc-order-title { font-family: 'Red Hat Display', sans-serif; font-weight: 700; font-size: 1.05rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.acc-order-desc { color: var(--acc-muted); font-size: .88rem; margin-top: .1rem; }
.acc-order-meta { display: flex; flex-wrap: nowrap; gap: .35rem 1rem; margin-top: .35rem; overflow: hidden; }
.acc-order-meta span { display: inline-flex; align-items: center; gap: .3rem; font-size: .85rem; color: var(--acc-muted); white-space: nowrap; }
.acc-order-meta [data-lucide] { width: 16px; height: 16px; }
.acc-order-side { display: flex; flex-direction: column; align-items: flex-end; gap: .4rem; flex-shrink: 0; }
.acc-order-amount { font-family: 'Red Hat Display', sans-serif; font-weight: 700; font-size: 1.05rem; }
.acc-order-empty {
    text-align: center; padding: 3rem 1rem; color: var(--acc-muted);
    background: #fff; border: 1px dashed var(--acc-border); border-radius: 14px;
}
.acc-order-empty [data-lucide] { width: 40px; height: 40px; margin-bottom: .5rem; opacity: .5; }
@media (max-width: 575px) {
    .acc-order-card { height: auto; min-height: 86px; flex-direction: column; align-items: stretch; }
    .acc-order-side { flex-direction: row; align-items: center; justify-content: space-between; }
    .acc-order-meta { flex-wrap: wrap; }
}

/* ---------- Pravni postupci (lista) ---------- */
.acc-procs { display: flex; flex-direction: column; gap: .85rem; }
.acc-proc-card {
    background: #fff; border: 1px solid var(--acc-border); border-radius: 14px;
    padding: 1.1rem 1.35rem;
    display: flex; align-items: center; gap: 1.1rem;
    box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
    transition: box-shadow .15s, transform .15s;
    text-decoration: none;
}
.acc-proc-card:hover { box-shadow: 0 6px 18px rgba(16, 24, 40, .08); transform: translateY(-1px); }
.acc-proc-icon {
    width: 52px; height: 52px; border-radius: 13px; flex-shrink: 0;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--acc-primary-soft); color: var(--acc-primary);
}
.acc-proc-icon [data-lucide] { width: 26px; height: 26px; }
.acc-proc-body { flex-grow: 1; min-width: 0; }
.acc-proc-title { font-family: 'Red Hat Display', sans-serif; font-weight: 700; font-size: 1.08rem; margin-bottom: .5rem; }
.acc-proc-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .5rem 1rem; }
.acc-proc-cell { display: flex; flex-direction: column; min-width: 0; }
.acc-proc-k { display: inline-flex; align-items: center; gap: .3rem; font-size: .7rem; text-transform: uppercase; letter-spacing: .3px; color: var(--acc-muted); }
.acc-proc-k [data-lucide] { width: 13px; height: 13px; }
.acc-proc-v { font-weight: 600; font-size: .9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.acc-proc-status { display: flex; flex-direction: column; align-items: flex-end; gap: .5rem; flex-shrink: 0; }
.acc-proc-arrow { width: 18px; height: 18px; color: var(--acc-muted); }
@media (max-width: 767px) {
    .acc-proc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .acc-proc-card { flex-wrap: wrap; }
}

/* ---------- Inbox thread (chat) ---------- */
.acc-thread { display: flex; flex-direction: column; gap: .75rem; }
.acc-msg { display: flex; }
.acc-msg-me { justify-content: flex-end; }
.acc-msg-other { justify-content: flex-start; }
.acc-msg-bubble {
    max-width: 78%;
    background: #fff; border: 1px solid var(--acc-border); border-radius: 14px;
    padding: .75rem 1rem; box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
}
.acc-msg-me .acc-msg-bubble { background: var(--acc-primary-soft); border-color: #dfe3fb; }
.acc-msg-who { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .3px; color: var(--acc-muted); margin-bottom: .2rem; }
.acc-msg-body { line-height: 1.5; }
.acc-msg-time { font-size: .7rem; color: var(--acc-muted); margin-top: .3rem; }

/* ---------- Pravni postupci ---------- */
.acc-proc-meta .acc-proc-label {
    display: inline-flex; align-items: center; gap: .35rem;
    font-size: .75rem; text-transform: uppercase; letter-spacing: .3px; color: var(--acc-muted);
}
.acc-proc-meta [data-lucide] { width: 15px; height: 15px; }
.acc-docs .accordion-item { border: 1px solid var(--acc-border); border-radius: 12px !important; margin-bottom: .6rem; overflow: hidden; }
.acc-docs .accordion-button { font-family: 'Red Hat Display', sans-serif; min-height: 64px; }
.acc-docs .accordion-button:not(.collapsed) { background: var(--acc-primary-soft); color: var(--acc-primary); box-shadow: none; }
.acc-docs .accordion-button:focus { box-shadow: none; border-color: var(--acc-border); }
.acc-doc-icon {
    width: 32px; height: 32px; border-radius: 9px; flex-shrink: 0;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--acc-primary-soft); color: var(--acc-primary); margin-right: .65rem;
}
.acc-doc-icon [data-lucide] { width: 18px; height: 18px; }

/* ---------- Kompanije / dokumenti (kljuc-vrijednost) ---------- */
.acc-kv { display: flex; flex-direction: column; gap: .3rem; font-size: .88rem; }
.acc-kv [data-lucide] { width: 15px; height: 15px; vertical-align: -2px; }
.acc-kv .text-secondary { font-size: .8rem; }

/* ---------- E-potpis (signature pad) ---------- */
.acc-sign-wrap {
    border: 2px dashed var(--acc-border); border-radius: 12px;
    background: repeating-linear-gradient(180deg, #fff, #fff 31px, #f1f3f8 32px);
    overflow: hidden;
}
.acc-sign-pad { width: 100%; height: 200px; display: block; touch-action: none; cursor: crosshair; }
.acc-sign-preview { max-width: 320px; border: 1px solid var(--acc-border); border-radius: 10px; background: #fff; }
.contract-body { white-space: pre-wrap; line-height: 1.7; }
