:root {
    --sidebar-width: 220px;
    --header-height: 76px;
    --background: #f4f6f8;
    --surface: #ffffff;
    --surface-soft: #f8fafc;
    --border: #e5e7eb;
    --text: #172033;
    --muted: #6b7280;
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-soft: #eff6ff;
    --sidebar: #111827;
    --sidebar-soft: #1f2937;
    --sidebar-text: #d1d5db;
    --sidebar-muted: #9ca3af;
    --danger: #ef4444;
    --shadow-sm: 0 6px 20px rgba(15, 23, 42, 0.06);
    --shadow-lg: 0 24px 50px rgba(15, 23, 42, 0.18);
    --radius-sm: 10px;
    --radius-md: 14px;
    --transition: 220ms ease;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    min-height: 100%;
    background: var(--background);
}

body {
    min-height: 100vh;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text);
    background: var(--background);
}

body.menu-open {
    overflow: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

button {
    font: inherit;
}

@media (max-width: 768px) {
    .mobile-hide,
    .page-heading__description {
        display: none !important;
    }
}

/* =========================================================
   LOGIN STRANICA
   ========================================================= */

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #dbeafe;

    --sidebar-dark: #0f172a;
    --sidebar-medium: #172033;

    --text-dark: #111827;
    --text-medium: #475569;
    --text-light: #94a3b8;

    --background: #f8fafc;
    --white: #ffffff;
    --border: #e2e8f0;

    --danger: #dc2626;
    --danger-background: #fef2f2;
    --danger-border: #fecaca;

    --success: #15803d;
    --success-background: #f0fdf4;
    --success-border: #bbf7d0;

    --shadow:
        0 24px 70px rgba(15, 23, 42, 0.14);

    --transition: 0.2s ease;
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
}

body {
    margin: 0;
    min-height: 100%;
    font-family: "Inter", Arial, sans-serif;
    color: var(--text-dark);
    background: var(--background);
}

button,
input {
    font: inherit;
}

.login-body {
    min-height: 100vh;
    overflow-x: hidden;
}

.login-page {
    display: grid;
    grid-template-columns: minmax(420px, 0.95fr) minmax(520px, 1.05fr);
    min-height: 100vh;
}

/* =========================================================
   LIJEVA STRANA
   ========================================================= */

.login-intro {
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    padding: 46px 58px 34px;
    overflow: hidden;
    color: var(--white);
    background:
        radial-gradient(
            circle at 15% 15%,
            rgba(59, 130, 246, 0.35),
            transparent 35%
        ),
        radial-gradient(
            circle at 85% 75%,
            rgba(37, 99, 235, 0.22),
            transparent 34%
        ),
        linear-gradient(
            145deg,
            var(--sidebar-dark) 0%,
            var(--sidebar-medium) 100%
        );
}

.login-intro::before {
    content: "";
    position: absolute;
    top: -140px;
    right: -120px;
    width: 360px;
    height: 360px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 50%;
}

.login-intro::after {
    content: "";
    position: absolute;
    right: 80px;
    bottom: -210px;
    width: 430px;
    height: 430px;
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 50%;
}

.login-brand,
.login-mobile-logo {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 14px;
}

.login-brand-icon {
    display: grid;
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
    place-items: center;
    border-radius: 14px;
    font-size: 17px;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: var(--white);
    background: var(--primary);
    box-shadow: 0 12px 25px rgba(37, 99, 235, 0.35);
}

.login-brand strong,
.login-mobile-logo strong {
    display: block;
    margin-bottom: 3px;
    font-size: 18px;
    font-weight: 800;
}

.login-brand span,
.login-mobile-logo span {
    display: block;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
}

.login-intro-content {
    position: relative;
    z-index: 2;
    max-width: 570px;
    margin: auto 0;
    padding: 70px 0;
}

.login-eyebrow {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    margin-bottom: 22px;
    padding: 7px 12px;
    border: 1px solid rgba(147, 197, 253, 0.2);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #bfdbfe;
    background: rgba(37, 99, 235, 0.12);
}

.login-intro-content h1 {
    max-width: 590px;
    margin: 0 0 22px;
    font-size: clamp(38px, 4.4vw, 66px);
    line-height: 1.04;
    letter-spacing: -0.055em;
}

.login-intro-content > p {
    max-width: 520px;
    margin: 0;
    font-size: 17px;
    line-height: 1.75;
    color: rgba(255, 255, 255, 0.68);
}

.login-features {
    display: grid;
    gap: 15px;
    margin-top: 40px;
}

.login-feature {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.84);
}

.login-feature-check {
    display: grid;
    flex: 0 0 26px;
    width: 26px;
    height: 26px;
    place-items: center;
    border: 1px solid rgba(147, 197, 253, 0.25);
    border-radius: 50%;
    font-size: 13px;
    color: #bfdbfe;
    background: rgba(37, 99, 235, 0.16);
}

.login-intro-footer {
    position: relative;
    z-index: 2;
    margin: 0;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.38);
}

/* =========================================================
   DESNA STRANA I FORMA
   ========================================================= */

.login-form-section {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 56px;
    background:
        linear-gradient(
            rgba(248, 250, 252, 0.94),
            rgba(248, 250, 252, 0.94)
        ),
        radial-gradient(
            circle at top right,
            var(--primary-light),
            transparent 35%
        );
}

.login-mobile-logo {
    display: none;
}

.login-mobile-logo span {
    color: var(--text-medium);
}

.login-form {
    width: 100%;
    max-width: 470px;
    padding: 42px;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: var(--shadow);
    backdrop-filter: blur(12px);
}

.login-form-header {
    margin-bottom: 30px;
}

.login-form-label {
    display: block;
    margin-bottom: 9px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--primary);
}

.login-form-header h2 {
    margin: 0 0 10px;
    font-size: 30px;
    line-height: 1.2;
    letter-spacing: -0.035em;
}

.login-form-header p {
    margin: 0;
    font-size: 14px;
    line-height: 1.65;
    color: var(--text-medium);
}

/* =========================================================
   PORUKE
   ========================================================= */

.login-message {
    margin-bottom: 22px;
    padding: 13px 15px;
    border: 1px solid;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.5;
}

.login-message-error {
    border-color: var(--danger-border);
    color: var(--danger);
    background: var(--danger-background);
}

.login-message-success {
    border-color: var(--success-border);
    color: var(--success);
    background: var(--success-background);
}

/* =========================================================
   POLJA FORME
   ========================================================= */

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 700;
    color: #334155;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 15px;
    display: grid;
    place-items: center;
    pointer-events: none;
    color: var(--text-light);
    transition: color var(--transition);
}

.input-wrapper input {
    width: 100%;
    height: 52px;
    padding: 0 48px 0 46px;
    border: 1px solid var(--border);
    border-radius: 11px;
    outline: none;
    font-size: 14px;
    color: var(--text-dark);
    background: var(--white);
    transition:
        border-color var(--transition),
        box-shadow var(--transition),
        background var(--transition);
}

.input-wrapper input::placeholder {
    color: #a8b2c1;
}

.input-wrapper input:hover {
    border-color: #cbd5e1;
}

.input-wrapper input:focus {
    border-color: var(--primary);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.input-wrapper:focus-within .input-icon {
    color: var(--primary);
}

.password-toggle {
    position: absolute;
    right: 10px;
    display: grid;
    width: 34px;
    height: 34px;
    padding: 0;
    place-items: center;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    color: var(--text-light);
    background: transparent;
    transition:
        color var(--transition),
        background var(--transition);
}

.password-toggle:hover {
    color: var(--primary);
    background: var(--primary-light);
}

.password-toggle:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* =========================================================
   DUGME
   ========================================================= */

.login-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    width: 100%;
    min-height: 53px;
    margin-top: 26px;
    padding: 13px 20px;
    border: 0;
    border-radius: 11px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 800;
    color: var(--white);
    background:
        linear-gradient(
            135deg,
            var(--primary),
            var(--primary-dark)
        );
    box-shadow: 0 11px 24px rgba(37, 99, 235, 0.25);
    transition:
        transform var(--transition),
        box-shadow var(--transition),
        filter var(--transition);
}

.login-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 15px 28px rgba(37, 99, 235, 0.3);
    filter: brightness(1.03);
}

.login-submit:active {
    transform: translateY(0);
}

.login-submit:focus-visible {
    outline: 3px solid rgba(37, 99, 235, 0.3);
    outline-offset: 3px;
}

.login-security-note {
    margin: 20px 0 0;
    text-align: center;
    font-size: 11px;
    line-height: 1.5;
    color: var(--text-light);
}

/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 1050px) {
    .login-page {
        grid-template-columns: minmax(360px, 0.8fr) minmax(460px, 1.2fr);
    }

    .login-intro {
        padding-right: 42px;
        padding-left: 42px;
    }

    .login-intro-content h1 {
        font-size: 44px;
    }

    .login-form-section {
        padding: 40px;
    }
}

@media (max-width: 820px) {
    .login-page {
        display: block;
        min-height: 100vh;
    }

    .login-intro {
        display: none;
    }

    .login-form-section {
        display: flex;
        flex-direction: column;
        min-height: 100vh;
        padding: 30px 20px;
    }

    .login-mobile-logo {
        display: flex;
        width: 100%;
        max-width: 470px;
        margin-bottom: 25px;
    }

    .login-mobile-logo strong {
        color: var(--text-dark);
    }

    .login-form {
        padding: 34px;
        border-radius: 20px;
    }
}

@media (max-width: 480px) {
    .login-form-section {
        justify-content: flex-start;
        padding: 22px 15px;
    }

    .login-mobile-logo {
        margin: 4px 0 22px;
    }

    .login-brand-icon {
        flex-basis: 44px;
        width: 44px;
        height: 44px;
        border-radius: 12px;
        font-size: 15px;
    }

    .login-form {
        padding: 27px 21px;
        border-radius: 17px;
    }

    .login-form-header {
        margin-bottom: 25px;
    }

    .login-form-header h2 {
        font-size: 26px;
    }

    .input-wrapper input {
        height: 50px;
    }

    .login-submit {
        min-height: 51px;
    }
}



/* DASHBOARD */

.app-layout {
    min-height: 100vh;
}

.sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 1000;
    display: flex;
    width: var(--sidebar-width);
    min-height: 100vh;
    flex-direction: column;
    background:
        radial-gradient(circle at top left, rgba(37, 99, 235, 0.22), transparent 34%),
        var(--sidebar);
    color: var(--sidebar-text);
    box-shadow: 10px 0 30px rgba(15, 23, 42, 0.08);
}

.sidebar__header {
    display: flex;
    min-height: var(--header-height);
    align-items: center;
    justify-content: space-between;
    padding: 0 22px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar__brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
    color: #ffffff;
}

.sidebar__brand-mark {
    display: grid;
    width: 40px;
    height: 40px;
    place-items: center;
    border-radius: 12px;
    background: var(--primary);
    box-shadow: 0 10px 28px rgba(37, 99, 235, 0.32);
    font-size: 14px;
    letter-spacing: 0.04em;
}

.sidebar__brand-text {
    font-size: 18px;
}

.sidebar__close {
    display: none;
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
    cursor: pointer;
    font-size: 28px;
    line-height: 1;
}

.sidebar__nav {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 7px;
    padding: 24px 16px;
}

.sidebar__link {
    display: flex;
    min-height: 48px;
    align-items: center;
    gap: 13px;
    padding: 11px 14px;
    border-radius: var(--radius-sm);
    color: var(--sidebar-text);
    font-size: 15px;
    font-weight: 600;
    transition:
        background var(--transition),
        color var(--transition),
        transform var(--transition);
}

.sidebar__link:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
    transform: translateX(3px);
}

.sidebar__link--active {
    background: linear-gradient(135deg, var(--primary), #3b82f6);
    color: #ffffff;
    box-shadow: 0 14px 28px rgba(37, 99, 235, 0.22);
}

.sidebar__icon {
    display: inline-flex;
    width: 24px;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.sidebar__footer {
    padding: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar__logout {
    display: flex;
    min-height: 46px;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-sm);
    color: var(--sidebar-muted);
    font-weight: 700;
    transition: all var(--transition);
}

.sidebar__logout:hover {
    border-color: rgba(239, 68, 68, 0.45);
    background: rgba(239, 68, 68, 0.1);
    color: #fecaca;
}

.main-shell {
    min-height: 100vh;
    margin-left: var(--sidebar-width);
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 900;
    display: flex;
    min-height: var(--header-height);
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 14px 28px;
    border-bottom: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 4px 18px rgba(15, 23, 42, 0.035);
    backdrop-filter: blur(14px);
}

.topbar__left,
.topbar__actions {
    display: flex;
    align-items: center;
}

.topbar__left {
    gap: 14px;
}

.topbar__actions {
    gap: 10px;
}

.topbar__logo {
    display: inline-flex;
    overflow: hidden;
    align-items: center;
    border-radius: 9px;
}

.topbar__logo img {
    display: block;
    width: 170px;
    max-height: 46px;
    object-fit: contain;
}

.hamburger {
    display: none;
    width: 44px;
    height: 44px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    border: 1px solid var(--border);
    border-radius: 11px;
    background: var(--surface);
    cursor: pointer;
}

.hamburger span {
    display: block;
    width: 20px;
    height: 2px;
    border-radius: 999px;
    background: var(--text);
}

.button {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 16px;
    border: 1px solid transparent;
    border-radius: 11px;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
    transition:
        transform var(--transition),
        background var(--transition),
        border-color var(--transition),
        box-shadow var(--transition);
}

.button:hover {
    transform: translateY(-1px);
}

.button--primary {
    background: var(--primary);
    color: #ffffff;
    box-shadow: 0 10px 22px rgba(37, 99, 235, 0.18);
}

.button--primary:hover {
    background: var(--primary-dark);
}

.button--secondary {
    border-color: #bfdbfe;
    background: var(--primary-soft);
    color: var(--primary-dark);
}

.button--secondary:hover {
    border-color: #93c5fd;
    background: #dbeafe;
}

.button__icon {
    font-size: 18px;
    line-height: 1;
}

.user-menu {
    display: flex;
    align-items: center;
    min-height: 42px;
    padding: 0 14px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #ffffff;
}

.user-menu__name {
    font-size: 14px;
    font-weight: 700;
    color: #1f2937;
    white-space: nowrap;
}

.main-content {
    padding: 30px;
}

.page-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.page-heading__eyebrow {
    margin-bottom: 5px;
    color: var(--primary);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.page-heading h1 {
    font-size: clamp(26px, 3vw, 34px);
    line-height: 1.15;
}

.empty-content {
    min-height: calc(100vh - var(--header-height) - 145px);
    border: 1px dashed #d7dde6;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.54);
}

.sidebar-overlay {
    position: fixed;
    inset: 0;
    z-index: 950;
    visibility: hidden;
    background: rgba(15, 23, 42, 0.56);
    opacity: 0;
    transition:
        opacity var(--transition),
        visibility var(--transition);
}

.sidebar-overlay.is-visible {
    visibility: visible;
    opacity: 1;
}

@media (max-width: 1100px) {
    .topbar {
        align-items: flex-start;
    }

    .topbar__actions {
        flex-wrap: wrap;
        justify-content: flex-end;
    }
}

@media (max-width: 900px) {
    :root {
        --header-height: 68px;
    }

    .sidebar {
        inset: 0 0 0 auto;
        width: min(84vw, 320px);
        transform: translateX(105%);
        box-shadow: var(--shadow-lg);
        transition: transform var(--transition);
    }

    .sidebar.is-open {
        transform: translateX(0);
    }

    .sidebar__close {
        display: inline-grid;
        place-items: center;
    }

    .main-shell {
        margin-left: 0;
    }

    .hamburger {
        display: inline-flex;
    }

    .topbar {
        min-height: var(--header-height);
        align-items: center;
        padding: 11px 18px;
    }

    .topbar__logo img {
        width: 145px;
        max-height: 40px;
    }

    .topbar__actions {
        flex-wrap: nowrap;
    }

    .button {
        min-width: 44px;
        padding: 10px 12px;
    }

    .button span:not(.button__icon) {
        display: none;
    }
    
    .topbar__actions .button span:not(.button__icon) {
        display: block !important;
    }

    .user-menu__name,
    .user-menu__chevron {
        display: none;
    }

    .user-menu {
        margin-left: 0;
        padding-right: 5px;
        display: none;
    }

    .main-content {
        padding: 24px 18px;
    }
}

@media (max-width: 560px) {
    .topbar {
        gap: 10px;
        padding-inline: 12px;
    }

    .topbar__left {
        min-width: 0;
        gap: 9px;
    }

    .topbar__logo img {
        width: 118px;
    }

    .topbar__actions {
        gap: 6px;
    }

    .hamburger,
    .button,
    .user-menu {
        width: 40px;
        min-width: 40px;
        min-height: 40px;
        height: 40px;
        padding: 0;
    }

    .user-menu__avatar {
        width: 30px;
        height: 30px;
        border-radius: 8px;
    }

    .page-heading {
        margin-bottom: 18px;
    }

    .main-content {
        padding: 20px 14px;
    }

    .empty-content {
        min-height: calc(100vh - var(--header-height) - 122px);
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}

/* Customer */

.content-card {
    width: 100%;
    max-width: 760px;
    padding: 30px;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: 0 8px 28px rgba(15, 23, 42, 0.06);
}

.page-heading__description {
    margin: 8px 0 0;
    font-size: 14px;
    color: #64748b;
}

.admin-form {
    display: grid;
    gap: 24px;
}

.admin-form__group {
    display: grid;
    gap: 5px;
}

.admin-form__group label {
    font-size: 13px;
    font-weight: 600;
    color: #1f2937;
}

.required-mark {
    color: #dc2626;
}

.admin-form__group input {
    width: 100%;
    min-height: 50px;
    padding: 12px 14px;
    border: 1px solid #dbe1e8;
    border-radius: 10px;
    outline: none;
    font-size: 14px;
    color: #111827;
    background: #ffffff;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.admin-form__group input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.admin-form__help {
    margin: 0;
    font-size: 12px;
    color: #64748b;
}

.admin-form__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding-top: 6px;
}

.form-message {
    margin-bottom: 24px;
    padding: 15px 17px;
    border: 1px solid;
    border-radius: 10px;
    font-size: 13px;
    line-height: 1.6;
}

.form-message ul {
    margin: 8px 0 0;
    padding-left: 20px;
}

.form-message--error {
    border-color: #fecaca;
    color: #b91c1c;
    background: #fef2f2;
}

.button:disabled {
    cursor: not-allowed;
    opacity: 0.65;
}

.button.is-loading {
    pointer-events: none;
}

/* Tabela korisnika */

.content-card--wide {
    max-width: none;
}

.table-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
}

.table-header h2 {
    margin: 0 0 5px;
    font-size: 19px;
    color: #111827;
}

.table-header p {
    margin: 0;
    font-size: 13px;
    color: #64748b;
}

.admin-table-wrapper {
    width: 100%;
    overflow-x: auto;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
}

.admin-table {
    width: 100%;
    min-width: 760px;
    border-collapse: collapse;
    background: #ffffff;
}

.admin-table th,
.admin-table td {
    padding: 15px 12px;
    text-align: left;
    vertical-align: middle;
    border-bottom: 1px solid #e5e7eb;
}

.admin-table th {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #64748b;
    background: #f8fafc;
}

.admin-table td {
    font-size: 14px;
    color: #334155;
}

.admin-table tbody tr:last-child td {
    border-bottom: 0;
}

.admin-table tbody tr {
    transition: background-color 0.2s ease;
}

.admin-table tbody tr:hover {
    background: #f8fafc;
}

.admin-table tbody .admin-table__row--inactive {
    background: #fff5f5;
}

.admin-table tbody .admin-table__row--inactive:hover {
    background: #feecec;
}

.customer-name-link {
    font-weight: 750;
    text-decoration: none;
    color: #1d4ed8;
}

.customer-name-link:hover {
    text-decoration: underline;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    min-height: 27px;
    padding: 5px 10px;
    border: 1px solid;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
}

.status-badge--active {
    border-color: #bbf7d0;
    color: #15803d;
    background: #f0fdf4;
}

.status-badge--inactive {
    border-color: #fecaca;
    color: #b91c1c;
    background: #fef2f2;
}

.admin-table__actions-heading {
    text-align: right !important;
}

.admin-table__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    white-space: nowrap;
}

.table-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 8px 11px;
    border: 1px solid;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 750;
    text-decoration: none;
    transition:
        border-color 0.2s ease,
        background-color 0.2s ease,
        color 0.2s ease;
}

.table-button--edit {
    border-color: #dbe1e8;
    color: #334155;
    background: #ffffff;
}

.table-button--edit:hover {
    border-color: #94a3b8;
    background: #f8fafc;
}

.table-button--details {
    border-color: #bfdbfe;
    color: #1d4ed8;
    background: #eff6ff;
}

.table-button--details:hover {
    border-color: #93c5fd;
    background: #dbeafe;
}

.table-empty-value {
    font-size: 13px;
    font-style: italic;
    color: #94a3b8;
}

.empty-state {
    padding: 55px 20px;
    text-align: center;
}

.empty-state h3 {
    margin: 0 0 8px;
    font-size: 19px;
    color: #111827;
}

.empty-state p {
    margin: 0 0 22px;
    font-size: 14px;
    color: #64748b;
}

@media (max-width: 768px) {
    .table-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .admin-table-wrapper {
        overflow: visible;
        border: 0;
    }

    .admin-table {
        display: block;
        min-width: 0;
        background: transparent;
    }

    .admin-table thead {
        display: none;
    }

    .admin-table tbody {
        display: grid;
        gap: 14px;
    }

    .admin-table tr {
        display: block;
        overflow: hidden;
        border: 1px solid #e5e7eb;
        border-radius: 12px;
        background: #ffffff;
    }

    .admin-table td {
        display: grid;
        grid-template-columns: 120px minmax(0, 1fr);
        gap: 15px;
        padding: 12px 15px;
        border-bottom: 1px solid #eef2f7;
        text-align: right;
    }

    .admin-table td::before {
        content: attr(data-label);
        text-align: left;
        font-size: 11px;
        font-weight: 800;
        letter-spacing: 0.04em;
        text-transform: uppercase;
        color: #64748b;
    }

    .admin-table td:last-child {
        border-bottom: 0;
    }

    .admin-table__customer {
        align-items: center;
    }

    .admin-table__actions {
        display: grid;
        grid-template-columns: 120px minmax(0, 1fr);
        white-space: normal;
    }

    .admin-table__actions::before {
        align-self: center;
    }

    .admin-table__actions .table-button {
        width: 100%;
        margin-bottom: 7px;
    }

    .admin-table__actions .table-button:last-child {
        margin-bottom: 0;
    }
}

.customer-table-tools {
    display: grid;
    grid-template-columns:
        minmax(260px, 1fr)
        minmax(190px, 240px)
        auto;
    align-items: end;
    gap: 18px;
    margin-bottom: 22px;
    padding: 18px;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    background: #f8fafc;
}

.customer-table-tools__label {
    display: block;
    margin-bottom: 8px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #64748b;
}

.customer-search__wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.customer-search__icon {
    position: absolute;
    left: 14px;
    pointer-events: none;
    font-size: 18px;
    color: #94a3b8;
}

.customer-search input,
.customer-sort select {
    width: 100%;
    min-height: 44px;
    border: 1px solid #dbe1e8;
    border-radius: 9px;
    outline: none;
    font-size: 14px;
    color: #1f2937;
    background: #ffffff;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.customer-search input {
    padding: 10px 42px 10px 42px;
}

.customer-sort select {
    padding: 10px 35px 10px 12px;
    cursor: pointer;
}

.customer-search input:focus,
.customer-sort select:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.customer-search__clear {
    position: absolute;
    right: 8px;
    display: grid;
    width: 30px;
    height: 30px;
    padding: 0;
    place-items: center;
    border: 0;
    border-radius: 7px;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    color: #64748b;
    background: transparent;
}

.customer-search__clear:hover {
    color: #111827;
    background: #eef2f7;
}

.customer-filter-buttons {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 4px;
    border: 1px solid #dbe1e8;
    border-radius: 10px;
    background: #ffffff;
}

.customer-filter-button {
    min-height: 36px;
    padding: 7px 11px;
    border: 0;
    border-radius: 7px;
    cursor: pointer;
    white-space: nowrap;
    font-size: 12px;
    font-weight: 750;
    color: #64748b;
    background: transparent;
    transition:
        color 0.2s ease,
        background-color 0.2s ease,
        box-shadow 0.2s ease;
}

.customer-filter-button:hover {
    color: #1d4ed8;
    background: #eff6ff;
}

.customer-filter-button.is-active {
    color: #ffffff;
    background: #2563eb;
    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.2);
}

.customer-filter-empty {
    margin-bottom: 18px;
    padding: 35px 20px;
    border: 1px dashed #cbd5e1;
    border-radius: 12px;
    text-align: center;
    background: #f8fafc;
}

.customer-filter-empty h3 {
    margin: 0 0 7px;
    font-size: 17px;
    color: #1f2937;
}

.customer-filter-empty p {
    margin: 0;
    font-size: 13px;
    color: #64748b;
}

.customer-table-row[hidden] {
    display: none !important;
}

.form-message--success {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 22px;
    padding: 14px 16px;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
    color: #166534;
    background: #f0fdf4;
    box-shadow: 0 4px 14px rgba(22, 101, 52, 0.08);
}

.form-message--success::before {
    content: "✓";
    display: grid;
    flex: 0 0 24px;
    width: 24px;
    height: 24px;
    place-items: center;
    border-radius: 50%;
    font-size: 13px;
    font-weight: 800;
    color: #ffffff;
    background: #22c55e;
}

@media (max-width: 1050px) {
    .customer-table-tools {
        grid-template-columns: 1fr 1fr;
    }

    .customer-status-filter {
        grid-column: 1 / -1;
    }

    .customer-filter-buttons {
        width: fit-content;
    }
}

@media (max-width: 768px) {
    .admin-table-wrapper {
        overflow: visible;
        border: 0;
        border-radius: 0;
    }

    .admin-table {
        display: block;
        min-width: 0;
        background: transparent;
    }

    .admin-table thead {
        display: none;
    }

    .admin-table tbody {
        display: grid;
        gap: 12px;
    }

    .admin-table tr.customer-table-row:hover {
        background: #ffffff;
    }

    .admin-table tr.admin-table__row--inactive {
        border-color: #fecaca;
        background: #fff5f5;
    }

    .admin-table tr.admin-table__row--inactive:hover {
        background: #fff5f5;
    }

    .admin-table td {
        display: block;
        padding: 0;
        border: 0;
        text-align: left;
    }

    .admin-table td::before {
        display: none;
        content: none;
    }

    /* Ime i prezime */
    .admin-table__customer {
        grid-column: 1;
        grid-row: 1;
        min-width: 0;
    }

    .customer-name-link {
        display: block;
        overflow: hidden;
        font-size: 16px;
        font-weight: 800;
        line-height: 1.35;
        color: #111827;
        text-decoration: none;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .customer-name-link:hover {
        text-decoration: none;
    }

    /* Sakrij broj telefona */
    .admin-table td[data-label="Broj telefona"] {
        display: none;
    }

    /* Status */
    .admin-table td[data-label="Status"] {
        grid-column: 2;
        grid-row: 1;
        justify-self: end;
    }

    .status-badge {
        min-height: 0px;
        padding: 3px 9px;
        font-size: 9px;
        font-weight: 600;
    }

    /* Akcije */
    .admin-table__actions {
        display: block;
        grid-column: 1 / -1;
        grid-row: 2;
        width: 100%;
        padding-top: 4px;
    }

    /* Sakrij Uredi klijenta */
    .admin-table__actions .table-button--edit {
        display: none;
    }

    /* Prikaži samo Detaljnije */
    .admin-table__actions .table-button--details {
        display: flex;
        width: 100%;
        min-height: 40px;
        margin: 0;
        padding: 9px 14px;
        border-radius: 9px;
        font-size: 13px;
    }
}

.admin-form__group select {
    width: 100%;
    min-height: 50px;
    padding: 12px 42px 12px 14px;
    border: 1px solid #dbe1e8;
    border-radius: 10px;
    outline: none;
    cursor: pointer;
    font-size: 14px;
    color: #111827;
    background-color: #ffffff;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.admin-form__group select:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.form-action-button .submit-button-text,
.form-action-button .form-action-button__text {
    display: inline-block;
}

@media (max-width: 900px) {
    .admin-form__actions .form-action-button {
        width: 100%;
        min-width: 0;
        min-height: 46px;
        height: auto;
        padding: 11px 16px;
    }

    .admin-form__actions .form-action-button span {
        display: inline-block;
    }

    .admin-form__actions .form-action-button .button__icon {
        display: inline-block;
    }

    .admin-form__actions .submit-button-text,
    .admin-form__actions .form-action-button__text {
        display: inline-block !important;
        white-space: normal;
    }
}

.customer-page-heading {
    align-items: center;
}

.customer-title-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.customer-title-row h1 {
    margin: 0;
}

.page-heading__actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.customer-details-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(280px, 0.8fr);
    gap: 22px;
    margin-bottom: 24px;
}

.customer-details-card,
.customer-summary-card,
.customer-future-section {
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: 0 8px 28px rgba(15, 23, 42, 0.05);
}

.customer-details-card {
    padding: 26px;
}

.customer-details-card__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 24px;
}

.customer-details-card__eyebrow,
.customer-summary-card__eyebrow {
    margin: 0 0 6px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #2563eb;
}

.customer-details-card__header h2,
.customer-future-section__header h2 {
    margin: 0;
    font-size: 20px;
    color: #111827;
}

.customer-details-card__edit {
    flex: 0 0 auto;
    font-size: 13px;
    font-weight: 700;
    color: #2563eb;
}

.customer-details-card__edit:hover {
    text-decoration: underline;
}

.customer-details-list {
    display: grid;
}

.customer-details-list__item {
    display: grid;
    grid-template-columns: minmax(130px, 0.4fr) minmax(0, 1fr);
    gap: 20px;
    padding: 12px 0;
    border-bottom: 1px solid #eef2f7;
}

.customer-details-list__item:first-child {
    padding-top: 0;
}

.customer-details-list__item:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.customer-details-list dt {
    font-size: 13px;
    font-weight: 700;
    color: #64748b;
}

.customer-details-list dd {
    margin: 0;
    font-size: 14px;
    font-weight: 650;
    color: #1f2937;
}

.customer-phone-link {
    color: #1d4ed8;
}

.customer-phone-link:hover {
    text-decoration: underline;
}

.customer-summary-card {
    display: flex;
    min-height: 250px;
    flex-direction: column;
    justify-content: center;
    padding: 28px;
    background:
        radial-gradient(
            circle at top right,
            rgba(37, 99, 235, 0.12),
            transparent 38%
        ),
        #ffffff;
}

.customer-summary-card__label {
    margin-top: 10px;
    font-size: 14px;
    font-weight: 700;
    color: #64748b;
}

.customer-summary-card__value {
    display: block;
    margin-top: 8px;
    font-size: clamp(30px, 4vw, 42px);
    line-height: 1.1;
    letter-spacing: -0.04em;
    color: #111827;
}

.customer-summary-card__note {
    margin: 18px 0 0;
    font-size: 12px;
    line-height: 1.6;
    color: #94a3b8;
}

.customer-future-section {
    padding: 26px;
}

.customer-future-section__header {
    margin-bottom: 20px;
}

.customer-future-placeholder {
    padding: 40px 20px;
    border: 1px dashed #cbd5e1;
    border-radius: 12px;
    text-align: center;
    background: #f8fafc;
}

.customer-future-placeholder h3 {
    margin: 0 0 8px;
    font-size: 17px;
    color: #1f2937;
}

.customer-future-placeholder p {
    max-width: 520px;
    margin: 0 auto;
    font-size: 13px;
    line-height: 1.6;
    color: #64748b;
}

@media (max-width: 900px) {
    .customer-details-grid {
        grid-template-columns: 1fr;
    }

    .customer-summary-card {
        min-height: 210px;
    }

    .customer-edit-button {
        min-width: auto;
    }

    .customer-edit-button .customer-edit-button__text {
        display: inline-block !important;
    }
}

@media (max-width: 768px) {
    .customer-page-heading {
        align-items: flex-start;
    }

    .page-heading__actions {
        width: 100%;
    }

    .page-heading__actions .customer-edit-button {
        flex: 1;
        width: auto;
        min-width: 0;
        min-height: 44px;
        height: auto;
        padding: 10px 14px;
    }

    .page-heading__actions .customer-edit-button span {
        display: inline-block !important;
    }

    .customer-details-card,
    .customer-summary-card,
    .customer-future-section {
        padding: 20px;
    }

    .customer-details-list__item {
        grid-template-columns: 1fr;
        gap: 6px;
        padding: 15px 0;
    }
}

@media (max-width: 480px) {
    .customer-title-row {
        gap: 9px;
    }

    .customer-title-row h1 {
        width: 100%;
    }

    .customer-summary-card__value {
        font-size: 32px;
    }
}

/* Vehicles */

.vehicle-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.vehicle-form-grid__full {
    grid-column: 1 / -1;
}

.customer-mode-card {
    margin-top: 12px;
    padding: 18px;
    border: 1px solid var(--border-color, #dfe3e8);
    border-radius: 12px;
    background: var(--surface-soft, #f8fafc);
}

.customer-mode-toggle {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 600;
}

.customer-mode-toggle input {
    width: 18px;
    height: 18px;
    margin: 0;
}

.new-customer-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    margin-top: 18px;
    padding-top: 18px;
    border-top: 1px solid var(--border-color, #dfe3e8);
}

.new-customer-fields[hidden] {
    display: none !important;
}

.field-is-disabled {
    opacity: 0.55;
}

@media (max-width: 760px) {
    .vehicle-form-grid {
        gap: 15px 10px !important;
    }
    .vehicle-form-grid,
    .new-customer-fields {
        grid-template-columns: 1fr 1fr;
    }

    .vehicle-form-grid__full {
        grid-column: auto;
    }
}

/* =========================================================
   KREIRANJE RADNOG NALOGA
   ========================================================= */

.order-form-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(220px, 1fr);
    gap: 20px;
    align-items: start;
}

.order-form-grid__full {
    grid-column: 1 / -1;
}

/* =========================================================
   TEXTAREA
   ========================================================= */

.admin-form__group textarea {
    width: 100%;
    min-height: 150px;
    padding: 13px 14px;
    border: 1px solid #dbe1e8;
    border-radius: 10px;
    outline: none;
    resize: vertical;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.6;
    color: #111827;
    background: #ffffff;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.admin-form__group textarea::placeholder {
    color: #94a3b8;
}

.admin-form__group textarea:hover {
    border-color: #cbd5e1;
}

.admin-form__group textarea:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.order-form-grid .admin-form__group {
    min-width: 0;
}

.order-form-grid input,
.order-form-grid select,
.order-form-grid textarea {
    width: 100%;
}

/* =========================================================
   PRETRAGA VOZILA I MATERIJALA
   ========================================================= */

.order-combobox,
.material-picker {
    position: relative;
}

.order-suggestions {
    position: absolute;
    z-index: 60;
    top: calc(100% + 6px);
    right: 0;
    left: 0;
    max-height: 280px;
    overflow-y: auto;
    padding: 6px;
    border: 1px solid #dbe1e8;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.14);
}

.order-suggestions[hidden] {
    display: none !important;
}

.order-suggestion {
    display: block;
    width: 100%;
    padding: 11px 12px;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    font: inherit;
    color: #1f2937;
    background: transparent;
    text-align: left;
    transition:
        color 0.15s ease,
        background-color 0.15s ease;
}

.order-suggestion:hover,
.order-suggestion.is-active {
    color: #1d4ed8;
    background: #eff6ff;
}

.order-suggestion:focus-visible {
    outline: 2px solid #2563eb;
    outline-offset: -2px;
}

.order-suggestion__title {
    display: block;
    overflow: hidden;
    font-size: 14px;
    font-weight: 800;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.order-suggestion__meta {
    display: block;
    overflow: hidden;
    margin-top: 4px;
    font-size: 12px;
    line-height: 1.4;
    color: #64748b;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.order-suggestions__empty {
    padding: 12px;
    font-size: 13px;
    color: #64748b;
}

/* =========================================================
   VLASNIK VOZILA
   ========================================================= */

.owner-preview {
    display: flex;
    min-height: 50px;
    flex-direction: column;
    justify-content: center;
    padding: 10px 14px;
    border: 1px solid #dbe1e8;
    border-radius: 10px;
    background: #f8fafc;
}

.owner-preview__name {
    display: block;
    font-size: 14px;
    font-weight: 800;
    line-height: 1.35;
    color: #1f2937;
}

.owner-preview__phone {
    display: block;
    margin-top: 3px;
    font-size: 12px;
    line-height: 1.35;
    color: #64748b;
}

/* =========================================================
   SEKCIJA MATERIJALA
   ========================================================= */

.materials-section {
    margin-top: 4px;
    padding-top: 26px;
    border-top: 1px solid #e5e7eb;
}

.materials-section__header {
    margin-bottom: 18px;
}

.materials-section__header h2 {
    margin: 0 0 5px;
    font-size: 20px;
    line-height: 1.3;
    color: #111827;
}

.materials-section__header p {
    max-width: 620px;
    margin: 0;
    font-size: 13px;
    line-height: 1.6;
    color: #64748b;
}

.material-list {
    display: grid;
    gap: 12px;
}

.materials-empty {
    padding: 24px 18px;
    border: 1px dashed #cbd5e1;
    border-radius: 13px;
    font-size: 13px;
    line-height: 1.5;
    color: #64748b;
    background: #f8fafc;
    text-align: center;
}

.materials-empty[hidden] {
    display: none !important;
}

/* =========================================================
   KARTICA MATERIJALA — DESKTOP
   ========================================================= */

.material-row {
    display: grid;
    grid-template-columns:
        minmax(220px, 1.7fr)
        minmax(125px, 0.75fr)
        minmax(100px, 0.6fr)
        minmax(125px, 0.75fr)
        44px;
    align-items: end;
    gap: 12px;
    padding: 16px;
    border: 1px solid #dbe1e8;
    border-radius: 14px;
    background: #f8fafc;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.035);
}

.material-row__field {
    min-width: 0;
}

.material-row__field > label {
    display: block;
    margin-bottom: 7px;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.35;
    color: #475569;
}

.material-row input,
.material-row select {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    border: 1px solid #dbe1e8;
    border-radius: 9px;
    outline: none;
    font-family: inherit;
    font-size: 14px;
    color: #111827;
    background: #ffffff;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.material-row input:hover {
    border-color: #cbd5e1;
}

.material-row input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.material-row input::placeholder {
    color: #94a3b8;
}

/* Uklanja strelice iz number inputa u Chrome/Safari */

.material-row input[type="number"]::-webkit-inner-spin-button,
.material-row input[type="number"]::-webkit-outer-spin-button {
    margin: 0;
}

/* Status poklapanja materijala */

.material-match-status {
    min-height: 17px;
    margin: 6px 0 0;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.4;
    color: #64748b;
}

.material-match-status:empty {
    display: none;
}

.material-match-status--existing {
    color: #15803d;
}

.material-match-status--new {
    color: #b45309;
}

/* Ukupno po stavci */

.material-row__total {
    display: flex;
    min-height: 44px;
    align-items: center;
    padding: 10px 12px;
    overflow: hidden;
    border: 1px solid #dbe1e8;
    border-radius: 9px;
    font-size: 14px;
    font-weight: 800;
    color: #111827;
    background: #ffffff;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* X dugme */

.material-row__remove {
    display: inline-flex;
    width: 44px;
    min-width: 44px;
    height: 44px;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid #fecaca;
    border-radius: 9px;
    cursor: pointer;
    font-size: 22px;
    font-weight: 500;
    line-height: 1;
    color: #b91c1c;
    background: #fef2f2;
    box-shadow: none;
    transition:
        border-color 0.2s ease,
        color 0.2s ease,
        background-color 0.2s ease,
        transform 0.2s ease;
}

.material-row__remove:hover {
    border-color: #fca5a5;
    color: #991b1b;
    background: #fee2e2;
    transform: translateY(-1px);
}

/* =========================================================
   FOOTER MATERIJALA
   ========================================================= */

.materials-footer {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    gap: 14px;
    margin-top: 18px;
}

.order-summary {
    display: flex;
    flex: 1;
    margin: 0;
}

.order-summary__card {
    display: flex;
    min-width: 250px;
    flex: 1;
    flex-direction: column;
    justify-content: center;
    padding: 15px 18px;
    border: 1px solid #bfdbfe;
    border-radius: 13px;
    background:
        radial-gradient(
            circle at top right,
            rgba(37, 99, 235, 0.1),
            transparent 42%
        ),
        #eff6ff;
}

.order-summary__label {
    display: block;
    font-size: 11px;
    font-weight: 800;
    line-height: 1.4;
    letter-spacing: 0.025em;
    text-transform: uppercase;
    color: #475569;
}

.order-summary__value {
    display: block;
    margin-top: 4px;
    font-size: 23px;
    font-weight: 850;
    line-height: 1.2;
    letter-spacing: -0.025em;
    color: #1d4ed8;
}

/*
 * Dugme treba imati id="addMaterialButton".
 * Može biti direktno dijete .materials-footer elementa.
 */

.materials-footer #addMaterialButton {
    align-self: stretch;
    min-width: 180px;
    min-height: 72px;
    padding: 12px 18px;
    border-radius: 13px;
}

.materials-footer #addMaterialButton .button__icon {
    font-size: 20px;
}

/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 1050px) {
    .material-row {
        grid-template-columns:
            minmax(0, 1.5fr)
            minmax(120px, 0.8fr)
            minmax(100px, 0.7fr);
    }

    .material-row__field:nth-of-type(4) {
        grid-column: 1 / 3;
    }

    .material-row__remove {
        grid-column: 3;
        justify-self: end;
    }
}

@media (max-width: 760px) {
    .order-form-grid {
        grid-template-columns: 1fr;
    }

    .order-form-grid__full {
        grid-column: auto;
    }

    .materials-section {
        padding-top: 21px;
    }

    /*
     * Mobilna kartica:
     * red 1: naziv | dobavljač
     * red 2: nabavna | prodajna | količina
     *
     * X je u gornjem desnom uglu kartice.
     */

    .material-row {
        position: relative;
        grid-template-columns: repeat(6, minmax(0, 1fr));
        gap: 10px;
        padding: 12px;
        padding-top: 40px;
        border-radius: 12px;
    }

    /*
     * Prvi red:
     * naziv i dobavljač zauzimaju po pola širine.
     */

    .material-row__name,
    .material-row__field:nth-of-type(1) {
        grid-column: span 3;
        grid-row: 1;
    }

    .material-row__supplier,
    .material-row__field:nth-of-type(2) {
        grid-column: span 3;
        grid-row: 1;
    }

    /*
     * Drugi red:
     * nabavna, prodajna i količina
     * zauzimaju po trećinu širine.
     */

    .material-row__unit,
    .material-row__field:nth-of-type(3) {
        grid-column: span 2;
        grid-row: 2;
    }

    .material-row__selling,
    .material-row__field:nth-of-type(4) {
        grid-column: span 2;
        grid-row: 2;
    }

    .material-row__amount,
    .material-row__field:nth-of-type(5) {
        grid-column: span 2;
        grid-row: 2;
    }

    /*
     * X dugme:
     * bez pozadine i bordera,
     * u gornjem desnom uglu kartice.
     */

    .material-row .material-row__remove,
    .material-row .material-row__remove.button {
        position: absolute;
        top: 7px;
        right: 7px;

        display: flex;
        align-items: center;
        justify-content: center;

        width: 28px;
        min-width: 28px;
        height: 28px;
        min-height: 28px;
        padding: 0;

        border: 0 !important;
        border-radius: 0;
        outline: none;
        background: transparent !important;
        box-shadow: none !important;

        color: #64748b;
        font-size: 23px;
        font-weight: 400;
        line-height: 1;
        cursor: pointer;
    }

    .material-row .material-row__remove:hover,
    .material-row .material-row__remove:focus,
    .material-row .material-row__remove:focus-visible {
        border: 0 !important;
        outline: none;
        background: transparent !important;
        box-shadow: none !important;
        color: #dc2626;
    }

    .material-row__field > label,
    .material-row .admin-form__group > label {
        /*margin-bottom: 5px;
        font-size: 10px;*/
    }

    .material-row input,
    .material-row select {
        width: 100%;
        min-width: 0;
        min-height: 42px;
        padding: 9px 10px;
        font-size: 13px;
    }

    .material-match-status {
        margin-top: 4px;
        font-size: 10px;
    }

    .order-suggestions {
        max-height: 230px;
    }

    /*
     * Footer:
     * ukupno i dugme ostaju u istom redu.
     */

    .materials-footer {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: stretch;
        gap: 9px;
        margin-top: 14px;
    }

    .order-summary {
        min-width: 0;
    }

    .order-summary__card {
        width: 100%;
        min-width: 0;
        padding: 12px 13px;
        border-radius: 11px;
    }

    .order-summary__label {
        font-size: 9px;
        line-height: 1.3;
    }

    .order-summary__value {
        margin-top: 3px;
        font-size: 19px;
    }

    .materials-footer #addMaterialButton {
        width: auto;
        min-width: 48px;
        min-height: 100%;
        height: auto;
        padding: 10px 13px;
        border-radius: 11px;
    }

    .materials-footer #addMaterialButton span {
        display: inline-block !important;
    }

    .materials-footer #addMaterialButton .button__icon {
        font-size: 19px;
    }
}

@media (max-width: 480px) {
    .materials-empty {
        padding: 20px 14px;
    }

    /*
     * Na veoma uskim ekranima krije se tekst dugmeta,
     * a ostaje samo + ikona.
     */

    .materials-footer #addMaterialButton span:not(.button__icon) {
        display: none !important;
    }

    .materials-footer #addMaterialButton {
        width: 48px;
        min-width: 48px;
        padding: 0;
    }

    .order-summary__value {
        font-size: 18px;
    }
}




/* =========================================================
   KREIRANJE TERMINA
   ========================================================= */

.slot-content-card {
    max-width: 860px;
}

.slot-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.slot-form-grid__full {
    grid-column: 1 / -1;
}

/* =========================================================
   PRETRAGA VOZILA
   ========================================================= */

.slot-combobox {
    position: relative;
}

.slot-suggestions {
    position: absolute;
    z-index: 70;
    top: calc(100% + 6px);
    right: 0;
    left: 0;
    max-height: 290px;
    overflow-y: auto;
    padding: 6px;
    border: 1px solid #dbe1e8;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.16);
}

.slot-suggestions[hidden] {
    display: none !important;
}

.slot-suggestion {
    display: block;
    width: 100%;
    padding: 11px 12px;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    font: inherit;
    color: #1f2937;
    background: transparent;
    text-align: left;
    transition:
        color 0.15s ease,
        background-color 0.15s ease;
}

.slot-suggestion:hover,
.slot-suggestion.is-active {
    color: #1d4ed8;
    background: #eff6ff;
}

.slot-suggestion__title {
    display: block;
    overflow: hidden;
    font-size: 14px;
    font-weight: 800;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.slot-suggestion__meta {
    display: block;
    overflow: hidden;
    margin-top: 4px;
    font-size: 12px;
    line-height: 1.4;
    color: #64748b;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.slot-suggestions__empty {
    padding: 12px;
    font-size: 13px;
    line-height: 1.55;
    color: #64748b;
}

/* =========================================================
   POSTOJEĆE / NOVO VOZILO
   ========================================================= */

.slot-mode-notice {
    display: flex;
    align-items: center;
    gap: 9px;
    min-height: 45px;
    padding: 11px 14px;
    border: 1px solid #fde68a;
    border-radius: 10px;
    font-size: 13px;
    line-height: 1.45;
    color: #92400e;
    background: #fffbeb;
}

.slot-mode-notice strong {
    flex: 0 0 auto;
}

.slot-mode-notice--existing {
    border-color: #bbf7d0;
    color: #166534;
    background: #f0fdf4;
}

.slot-field--readonly {
    cursor: default;
    color: #475569 !important;
    background: #f8fafc !important;
}

.slot-field--readonly:focus {
    border-color: #dbe1e8 !important;
    box-shadow: none !important;
}

/* =========================================================
   NASLOV SEKCIJE I POLJA
   ========================================================= */

.slot-section-heading {
    margin-top: 6px;
    padding-top: 24px;
    border-top: 1px solid #e5e7eb;
}

.slot-section-heading h2 {
    margin: 0;
    font-size: 19px;
    line-height: 1.3;
    color: #111827;
}

.admin-form__group textarea {
    width: 100%;
    min-height: 130px;
    padding: 13px 14px;
    border: 1px solid #dbe1e8;
    border-radius: 10px;
    outline: none;
    resize: vertical;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.6;
    color: #111827;
    background: #ffffff;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.admin-form__group textarea:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.admin-form__group input[type="date"] {
    cursor: pointer;
}

/* =========================================================
   MOBILNI PRIKAZ
   ========================================================= */

@media (max-width: 760px) {
    .slot-form-grid {
        grid-template-columns: 1fr;
    }

    .slot-form-grid__full {
        grid-column: auto;
    }

    .slot-mode-notice {
        align-items: flex-start;
        flex-direction: column;
        gap: 2px;
        padding: 10px 12px;
    }

    .slot-section-heading {
        padding-top: 20px;
    }

    .slot-suggestions {
        max-height: 240px;
    }
}








/* =========================================================
   LISTA TERMINA
   ========================================================= */

.slots-card {
    overflow: hidden;
}

.slots-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 20px;
}

.slots-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.slot-filter-capsule {
    min-height: 38px;
    padding: 8px 14px;
    border: 1px solid #dbe1e8;
    border-radius: 999px;
    cursor: pointer;
    font: inherit;
    font-size: 13px;
    font-weight: 750;
    color: #475569;
    background: #ffffff;
    transition:
        border-color 0.18s ease,
        color 0.18s ease,
        background-color 0.18s ease,
        box-shadow 0.18s ease;
}

.slot-filter-capsule:hover {
    border-color: #93c5fd;
    color: #1d4ed8;
    background: #eff6ff;
}

.slot-filter-capsule.is-active {
    border-color: #2563eb;
    color: #ffffff;
    background: #2563eb;
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.2);
}

.slots-result-count {
    flex: 0 0 auto;
    font-size: 13px;
    color: #64748b;
}

.slots-result-count strong {
    color: #111827;
}

.slots-table-wrap {
    width: 100%;
    overflow-x: auto;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
}

.slots-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 900px;
}

.slots-table th,
.slots-table td {
    padding: 14px 16px;
    border-bottom: 1px solid #e2e8f0;
    vertical-align: middle;
    text-align: left;
}

.slots-table th {
    font-size: 11px;
    font-weight: 850;
    letter-spacing: 0.035em;
    text-transform: uppercase;
    color: #64748b;
    background: #f8fafc;
}

.slots-table tbody tr:last-child td {
    border-bottom: 0;
}

.slots-table tbody tr:hover {
    background: #f8fafc;
}

.slot-date-value {
    font-size: 13px;
    font-weight: 750;
    color: #1f2937;
    white-space: nowrap;
}

.slot-time-capsule {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 62px;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 850;
    color: #1d4ed8;
    background: #eff6ff;
}

.slot-vehicle-cell,
.slot-customer-cell {
    display: flex;
    min-width: 150px;
    flex-direction: column;
    gap: 3px;
}

.slot-vehicle-cell strong,
.slot-customer-cell strong {
    font-size: 13px;
    color: #111827;
}

.slot-vehicle-cell span,
.slot-customer-cell span {
    font-size: 12px;
    color: #64748b;
}

.slot-notes-text {
    display: block;
    max-width: 290px;
    overflow: hidden;
    font-size: 13px;
    line-height: 1.45;
    color: #475569;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.slot-notes-empty {
    color: #94a3b8;
}

.slots-table__actions-heading,
.slots-table__actions {
    width: 1%;
    text-align: right !important;
    white-space: nowrap;
}

.slot-delete-button {
    display: inline-flex;
    min-height: 36px;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 7px 11px;
    border: 1px solid #fecaca;
    border-radius: 9px;
    cursor: pointer;
    font: inherit;
    font-size: 12px;
    font-weight: 800;
    color: #b91c1c;
    background: #fef2f2;
    transition:
        border-color 0.18s ease,
        color 0.18s ease,
        background-color 0.18s ease;
}

.slot-delete-button:hover {
    border-color: #fca5a5;
    color: #991b1b;
    background: #fee2e2;
}

.slot-delete-button > span:first-child {
    font-size: 18px;
    font-weight: 500;
    line-height: 1;
}

.slots-empty-state,
.slots-no-results {
    display: flex;
    min-height: 180px;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 6px;
    padding: 30px;
    border: 1px dashed #cbd5e1;
    border-radius: 14px;
    color: #64748b;
    background: #f8fafc;
    text-align: center;
}

.slots-empty-state strong {
    color: #1f2937;
}

.slots-no-results[hidden] {
    display: none !important;
}

.slot-table-row[hidden] {
    display: none !important;
}

@media (max-width: 900px) {
    .slots-toolbar {
        align-items: flex-start;
        flex-direction: column;
    }

    .slots-result-count {
        align-self: flex-end;
    }

    .slots-table-wrap {
        overflow: visible;
        border: 0;
        border-radius: 0;
    }

    .slots-table {
        min-width: 0;
    }

    .slots-table thead {
        display: none;
    }

    .slots-table,
    .slots-table tbody,
    .slots-table tr,
    .slots-table td {
        display: block;
        width: 100%;
    }

    .slots-table tbody {
        display: grid;
        gap: 12px;
    }

    .slots-table tr {
        overflow: hidden;
        border: 1px solid #dbe1e8;
        border-radius: 13px;
        background: #ffffff;
        box-shadow: 0 4px 14px rgba(15, 23, 42, 0.04);
    }

    .slots-table td {
        display: grid;
        grid-template-columns: 110px minmax(0, 1fr);
        align-items: center;
        gap: 12px;
        padding: 10px 13px;
        border-bottom: 1px solid #edf0f4;
        text-align: left !important;
    }

    .slots-table td::before {
        content: attr(data-label);
        font-size: 10px;
        font-weight: 850;
        letter-spacing: 0.035em;
        text-transform: uppercase;
        color: #64748b;
    }

    .slots-table td:last-child {
        border-bottom: 0;
    }

    .slot-notes-text {
        max-width: none;
        white-space: normal;
    }

    .slots-table__actions form {
        justify-self: start;
    }
}

@media (max-width: 520px) {
    .slot-filter-capsule {
        min-height: 34px;
        padding: 7px 11px;
        font-size: 12px;
    }

    .slots-table td {
        grid-template-columns: 82px minmax(0, 1fr);
        gap: 9px;
    }

    .slot-delete-button__text {
        display: none;
    }

    .slot-delete-button {
        width: 38px;
        min-width: 38px;
        padding: 0;
    }
}

/* =========================================================
   MOBILNE KARTICE: KLIJENTI I VOZILA
   Ovaj blok je namjerno na kraju fajla i ima prednost nad
   opštim mobilnim stilovima tabele iznad.
   ========================================================= */

.customer-table__main-link,
.vehicle-table__main-link {
    color: inherit;
    text-decoration: none;
}

.customer-table__main-link:hover,
.vehicle-table__main-link:hover {
    text-decoration: underline;
}

.customer-table__mobile-cell,
.vehicle-table__mobile-cell {
    display: none;
}

@media (max-width: 760px) {
    /* Naslov stranice i glavno dugme */
    .page-heading {
        align-items: stretch;
    }

    .page-heading > .button {
        width: auto;
        align-self: flex-start;
        justify-content: center;
    }

    .page-heading > .button .button__icon {
        display: inline-flex;
        flex: 0 0 auto;
        width: auto;
        min-width: 0;
    }

    /* Na telefonu ostaje samo pretraga */
    .customer-table-tools {
        display: block;
    }

    .customer-search,
    .customer-search__wrapper {
        width: 100%;
    }

    .customer-sort,
    .customer-status-filter {
        display: none !important;
    }

    /* Kartica i zaglavlje liste */
    .content-card--wide {
        padding-right: 12px;
        padding-left: 12px;
    }

    .table-header {
        margin-bottom: 14px;
    }

    .table-header h2 {
        font-size: 18px;
    }

    .table-header p,
    .customer-table-tools__label {
        font-size: 12px;
    }

    #customerSearch,
    #vehicleSearch {
        font-size: 14px;
    }

    /* Zajednički reset tabela */
    .admin-table-wrapper {
        overflow: visible;
    }

    .admin-table {
        display: block;
        width: 100%;
    }

    .admin-table thead {
        display: none;
    }

    .admin-table tbody {
        display: grid;
        gap: 10px;
    }

    .admin-table .customer-table-row,
    .admin-table .vehicle-table-row {
        position: relative;
        display: block;
        width: 100%;
        min-height: 0;
        padding: 0 !important;
        overflow: hidden;
        border: 1px solid var(--border-color, #e2e8f0);
        border-radius: 12px;
        background: var(--surface, #ffffff);
        box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
    }

    .admin-table .customer-table-row[hidden],
    .admin-table .vehicle-table-row[hidden] {
        display: none !important;
    }

    .admin-table .customer-table-row.admin-table__row--inactive,
    .admin-table .vehicle-table-row.admin-table__row--inactive {
        opacity: 0.72;
    }

    /* Sakrivanje desktop ćelija */
    .customer-table-row > td:not(.customer-table__mobile-cell),
    .vehicle-table-row > td:not(.vehicle-table__mobile-cell) {
        display: none !important;
    }

    /* Jedina mobilna ćelija */
    .customer-table-row > .customer-table__mobile-cell,
    .vehicle-table-row > .vehicle-table__mobile-cell {
        display: block !important;
        width: auto;
        padding: 0 !important;
        border: 0 !important;
    }

    .customer-table__mobile-cell::before,
    .vehicle-table__mobile-cell::before {
        display: none !important;
        content: none !important;
    }

    /* Zajednička struktura kartice */
    .customer-mobile-card,
    .vehicle-mobile-card {
        position: relative;
        min-width: 0;
        padding: 13px 50px 13px 14px;
    }

    .customer-mobile-card__main,
    .vehicle-mobile-card__main {
        display: block;
        min-width: 0;
        color: inherit;
        text-decoration: none;
    }

    .customer-mobile-card__main:hover,
    .vehicle-mobile-card__main:hover {
        text-decoration: none;
    }

    .customer-mobile-card__top,
    .vehicle-mobile-card__top {
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        gap: 7px;
        margin-bottom: 6px;
    }

    .customer-mobile-card__name,
    .vehicle-mobile-card__title {
        min-width: 0;
        max-width: 100%;
        overflow-wrap: anywhere;
        color: var(--text-color, #0f172a);
        font-size: 14px !important;
        font-weight: 750;
        line-height: 1.3;
    }

    .customer-mobile-card__status,
    .vehicle-mobile-card__status {
        flex: 0 0 auto;
    }

    .customer-mobile-card__status .status-badge,
    .vehicle-mobile-card__status .status-badge {
        padding: 3px 7px;
        font-size: 10px;
        line-height: 1.2;
    }

    /* Donji red kartice */
    .customer-mobile-card__phone,
    .vehicle-mobile-card__owner {
        display: flex;
        align-items: center;
        gap: 5px;
        min-width: 0;
        color: var(--text-muted, #64748b);
        font-size: 12px;
        line-height: 1.35;
    }

    .customer-mobile-card__phone-label,
    .vehicle-mobile-card__owner-label {
        flex: 0 0 auto;
    }

    .customer-mobile-card__phone-value,
    .vehicle-mobile-card__owner-name {
        min-width: 0;
        overflow: hidden;
        color: var(--text-color, #334155);
        font-weight: 650;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    /* Ikona za uređivanje */
    .customer-mobile-card__edit,
    .vehicle-mobile-card__edit {
        position: absolute;
        top: 50%;
        right: 11px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 31px;
        height: 31px;
        border: 1px solid var(--border-color, #e2e8f0);
        border-radius: 8px;
        color: var(--text-muted, #475569);
        background: var(--surface-soft, #f8fafc);
        text-decoration: none;
        transform: translateY(-50%);
    }

    .customer-mobile-card__edit:hover,
    .customer-mobile-card__edit:focus-visible,
    .vehicle-mobile-card__edit:hover,
    .vehicle-mobile-card__edit:focus-visible {
        border-color: var(--primary-color, #2563eb);
        color: var(--primary-color, #2563eb);
    }

    .customer-mobile-card__edit svg,
    .vehicle-mobile-card__edit svg {
        width: 14px;
        height: 14px;
        fill: none;
        stroke: currentColor;
        stroke-width: 2;
        stroke-linecap: round;
        stroke-linejoin: round;
    }
}

@media (max-width: 420px) {
    .customer-mobile-card,
    .vehicle-mobile-card {
        padding-top: 12px;
        padding-bottom: 12px;
    }

    .customer-mobile-card__name,
    .vehicle-mobile-card__title {
        font-size: 14px !important;
    }

    .customer-mobile-card__phone,
    .vehicle-mobile-card__owner {
        font-size: 11px;
    }
}






/* =========================================================
   SEDMIČNI PRIKAZ TERMINA
   ========================================================= */

.slots-page-heading {
    align-items: center;
}

.slots-week-section {
    width: 100%;
}

.slots-week-toolbar {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 18px;
}

.slots-week-toolbar h2 {
    margin: 0 0 5px;
    font-size: 20px;
    color: #111827;
}

.slots-week-toolbar p {
    margin: 0;
    font-size: 13px;
    color: #64748b;
}

.slots-week-picker {
    width: 220px;
    min-width: 220px;
}

.slots-week-picker label {
    display: block;
    margin-bottom: 7px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #64748b;
}

.slots-week-picker select {
    width: 100%;
    min-height: 44px;
    padding: 10px 36px 10px 12px;
    border: 1px solid #dbe1e8;
    border-radius: 10px;
    outline: none;
    cursor: pointer;
    font: inherit;
    font-size: 14px;
    color: #111827;
    background: #ffffff;
}

.slots-week-picker select:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.slots-week-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(210px, 1fr));
    gap: 12px;
    width: 100%;
    overflow-x: auto;
    padding: 0 0 8px;
    scroll-behavior: smooth;
}

.slots-day-column {
    min-width: 210px;
    background: transparent;
}

.slots-day-column__header {
    padding: 8px 8px 10px;
    border-bottom: 2px solid #e2e8f0;
}

.slots-day-column--today .slots-day-column__header {
    border-bottom-color: #2563eb;
    background-color: #2563eb;
    border-radius: 8px 8px 0 0;
}

.slots-day-column__name,
.slots-day-column__date {
    display: block;
}

.slots-day-column__name {
    font-size: 13px;
    font-weight: 850;
    color: #111827;
}

.slots-day-column__date {
    margin-top: 3px;
    font-size: 11px;
    color: #64748b;
}

.slots-day-column--today .slots-day-column__header .slots-day-column__name,
.slots-day-column--today .slots-day-column__header .slots-day-column__date {
    color: #FFF;
}

.slots-day-column__body {
    display: grid;
    gap: 9px;
    min-height: 160px;
    padding: 10px 0 0;
}

.slots-day-empty {
    display: grid;
    min-height: 120px;
    place-items: center;
    border: 1px dashed #d7dee8;
    border-radius: 10px;
    font-size: 12px;
    color: #94a3b8;
    background: #fafbfc;
}

.slot-card {
    height: fit-content;
    overflow: hidden;
    border: 1px solid #dbe1e8;
    border-radius: 11px;
    background: #ffffff;
    box-shadow: 0 3px 10px rgba(15, 23, 42, 0.04);
}

.slot-card__toggle {
    position: relative;
    display: block;
    width: 100%;
    padding: 11px;
    border: 0;
    cursor: pointer;
    color: inherit;
    background: transparent;
    text-align: left;
}

.slot-card__toggle:hover {
    background: #f8fafc;
}

.slot-card__time {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 7px;
    padding: 2px 6px;
    border-radius: 2px;
    font-size: 11px;
    font-weight: 700;
    color: #1d4ed8;
    background: #eff6ff;
}

.slot-card__content {
    display: block;
    min-width: 0;
}

.slot-card__notes,
.slot-card__vehicle,
.slot-card__customer {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
}

.slot-card__notes {
    font-size: 12px;
    font-weight: 750;
    line-height: 1.4;
    color: #111827;
    white-space: normal;
}

.slot-card__vehicle {
    margin-top: 4px;
    font-size: 11px;
    line-height: 1.35;
    color: #475569;
    white-space: nowrap;
}

.slot-card__details {
    max-height: 0;
    overflow: hidden;
    border-top: 0 solid #e2e8f0;
    transition:
        max-height 0.28s ease,
        border-top-width 0.28s ease;
}

.slot-card--open .slot-card__details {
    border-top-width: 1px;
}

.slot-card__details-inner {
    padding: 11px;
}

.slot-card__meta {
    display: grid;
    gap: 8px;
}

.slot-card__meta-item {
    display: block;
}

.slot-card__meta dt {
    margin-bottom: 2px;
    font-size: 9px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #94a3b8;
}

.slot-card__meta dd {
    margin: 0;
    overflow-wrap: anywhere;
    font-size: 12px;
    font-weight: 650;
    line-height: 1.4;
    color: #334155;
}

.slot-card__meta-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.slot-card__meta-row .slot-card__meta-item {
    min-width: 0;
}

.slot-card__meta a {
    color: #1d4ed8;
}

.slot-card__actions {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-top: 13px;
}

.slot-card__action {
    min-height: 32px;
    height: 32px !important;
    padding: 5px 10px !important;
    font-size: 11px;
    border-radius: 5px !important;
    width: fit-content !important;
}

.slot-card__delete {
    display: inline-flex;
    width: 34px;
    min-width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid #fecaca;
    border-radius: 8px;
    cursor: pointer;
    font-size: 20px;
    color: #b91c1c;
    background: #fef2f2;
}

.slot-card__delete:hover {
    border-color: #fca5a5;
    background: #fee2e2;
}

.slots-day-column.slots-day-column--today .slot-card {
    box-shadow: 0 1px 3px rgba(37, 99, 235, 0.5) !important;
}

@media (max-width: 900px) {
    .slots-week-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .slots-week-picker {
        width: 100%;
        min-width: 0;
    }

    .slots-week-grid {
        grid-template-columns:
            repeat(7, minmax(240px, 1fr));
    }
}

@media (max-width: 560px) {
    .slots-week-section {
        width: calc(100% + 28px);
        margin-left: -14px;
    }

    .slots-week-toolbar {
        padding: 0 14px;
    }

    .slots-week-grid {
        grid-template-columns:
            repeat(7, minmax(86vw, 1fr));
        gap: 10px;
        padding: 0 14px 8px;
        scroll-snap-type: x mandatory;
        scroll-padding-left: 14px;
    }

    .slots-day-column {
        min-width: 86vw;
        scroll-snap-align: start;
    }

    .slot-card__notes {
        white-space: normal;
    }
}



/* ==========================================================================
   Radni nalog – osnovna forma
   ========================================================================== */

.order-content-card {
    max-width: 1180px;
}

.order-form-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
}

.order-form-grid__full {
    grid-column: 1 / -1;
}

.order-combobox {
    position: relative;
}


/* ==========================================================================
   Prijedlozi vozila
   ========================================================================== */

.order-suggestions {
    position: absolute;
    z-index: 50;
    top: calc(100% + 6px);
    right: 0;
    left: 0;
    max-height: 280px;
    overflow-y: auto;
    padding: 6px;
    border: 1px solid #dbe1e8;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.14);
}

.order-suggestions[hidden] {
    display: none !important;
}

.order-suggestion {
    display: block;
    width: 100%;
    padding: 11px 12px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #1f2937;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.order-suggestion:hover,
.order-suggestion.is-active {
    background: #eff6ff;
}

.order-suggestion__number {
    display: block;
    font-size: 14px;
    font-weight: 800;
}

.order-suggestion__meta {
    display: block;
    margin-top: 3px;
    color: #64748b;
    font-size: 12px;
}


/* ==========================================================================
   Opis radnog naloga
   ========================================================================== */

.order-content-card .admin-form__group textarea {
    width: 100%;
    min-height: 125px;
    padding: 13px 14px;
    border: 1px solid #dbe1e8;
    border-radius: 10px;
    outline: none;
    resize: vertical;
    font: inherit;
}

.order-content-card .admin-form__group textarea:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}


/* ==========================================================================
   Materijali radnog naloga
   ========================================================================== */

.materials-section {
    margin-top: 28px;
}

.materials-header {
    margin-bottom: 14px;
}

.materials-header h2 {
    margin: 0 0 5px;
    font-size: 20px;
    line-height: 1.3;
}

.material-row {
    display: grid;
    grid-template-columns:
        minmax(210px, 2fr)
        minmax(170px, 1.3fr)
        repeat(3, minmax(110px, 1fr))
        44px;
    gap: 12px;
    align-items: end;
    margin-bottom: 12px;
    padding: 14px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #f8fafc;
}

.material-row .admin-form__group {
    min-width: 0;
}

.material-row input,
.material-row select {
    width: 100%;
    min-width: 0;
}

.material-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    min-width: 44px;
    height: 44px;
    padding: 0;
    font-size: 22px;
    line-height: 1;
}

.add-material-button {
    width: 100%;
    margin-top: 4px;
}


/* ==========================================================================
   Obračun
   ========================================================================== */

.order-calculation {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    margin-top: 24px;
}

.order-calculation__item {
    padding: 16px;
    border: 1px solid #dbe1e8;
    border-radius: 12px;
    background: #ffffff;
}

.order-calculation__label {
    display: block;
    color: #64748b;
    font-size: 13px;
    line-height: 1.4;
}

.order-calculation__value {
    display: block;
    margin-top: 5px;
    font-size: 21px;
    font-weight: 800;
    line-height: 1.3;
}

.order-calculation__item--profit {
    border-color: #bfdbfe;
    background: #eff6ff;
}


/* ==========================================================================
   Kreiranje vozila iz radnog naloga
   ========================================================================== */

.vehicle-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.customer-section {
    grid-column: 1 / -1;
    margin-top: 6px;
}

.customer-switcher {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin: 20px 0;
    padding: 6px;
    border: 1px solid #dfe3e8;
    border-radius: 14px;
    background: #f8fafc;
}

.customer-switcher > div {
    position: relative;
    min-width: 0;
}

.customer-switcher input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.customer-switcher label {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 10px 14px;
    border: 1px solid transparent;
    border-radius: 10px;
    color: #64748b;
    font-weight: 700;
    text-align: center;
    cursor: pointer;
    transition:
        background-color 0.18s ease,
        border-color 0.18s ease,
        color 0.18s ease,
        box-shadow 0.18s ease;
}

.customer-switcher input:checked + label {
    border-color: #2563eb;
    background: #ffffff;
    color: #2563eb;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.08);
}

.customer-switcher input:focus-visible + label {
    outline: 3px solid rgba(37, 99, 235, 0.18);
    outline-offset: 2px;
}

.customer-panel {
    padding: 20px;
    border: 1px solid #dfe3e8;
    border-radius: 14px;
    background: #ffffff;
}

.customer-panel[hidden] {
    display: none !important;
}

.customer-panel-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.customer-combobox {
    position: relative;
}

.customer-combobox > label {
    display: block;
    margin-bottom: 8px;
}

.customer-suggestions {
    position: absolute;
    z-index: 30;
    top: calc(100% + 6px);
    right: 0;
    left: 0;
    max-height: 260px;
    overflow-y: auto;
    padding: 6px;
    border: 1px solid #dfe3e8;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.14);
}

.customer-suggestions[hidden] {
    display: none !important;
}

.customer-suggestion {
    display: block;
    width: 100%;
    padding: 11px 12px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #1f2937;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.customer-suggestion:hover,
.customer-suggestion.is-active {
    background: #f1f5f9;
}


/* ==========================================================================
   Mobilni prikaz
   ========================================================================== */

@media (max-width: 760px) {
    .order-form-grid {
        grid-template-columns: 1fr;
    }

    .order-form-grid__full {
        grid-column: auto;
    }

    /*
     * Prvi red:
     * naziv + dobavljač
     *
     * Drugi red:
     * nabavna + prodajna + količina
     */
    .material-row {
        grid-template-columns: repeat(6, minmax(0, 1fr));
        gap: 12px;
        padding: 12px;
        padding-top: 18px;
    }

    .material-row__name {
        grid-column: span 3;
    }

    .material-row__supplier {
        grid-column: span 3;
    }

    .material-row__unit {
        grid-column: span 2;
    }

    .material-row__selling {
        grid-column: span 2;
    }

    .material-row__amount {
        grid-column: span 2;
    }

    .material-remove {
        position: absolute !important;
        top: 0px;
        right: 8px;
        height: fit-content;
        width: fit-content;
        min-width: 0px;
        background-color: transparent;
        border: none;
        font-size: 26px;
    }

    .order-calculation {
        grid-template-columns: 1fr;
    }

    .vehicle-form-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .customer-section {
        grid-column: 1 / -1;
    }

    .customer-panel {
        padding: 16px;
    }

    .customer-panel-grid {
        grid-template-columns: 1fr;
    }

    .customer-switcher label {
        padding-right: 8px;
        padding-left: 8px;
        font-size: 13px;
    }
}

@media (max-width: 460px) {
    /*
     * Na veoma uskim telefonima naziv i dobavljač
     * ostaju u prvom redu, svaki zauzima polovinu.
     */
    .material-row {
        gap: 10px;
    }

    .material-row label {
        font-size: 12px;
    }

    .material-row input,
    .material-row select {
        padding-right: 8px;
        padding-left: 8px;
        font-size: 13px;
    }
}













@media (max-width: 768px) {
    .content-card {
        padding: 0px;
        background-color: transparent;
        border: none;
        box-shadow: none;
        border-radius: 0px;
    }

    .content-card--wide {
        padding: 0px !important;
    }

    .admin-form__actions {
        flex-direction: column-reverse;
        align-items: stretch;
    }

    .admin-form__actions .button {
        width: 100%;
    }

    .admin-form__group input,
    .admin-form__group select,
    .admin-form__group textarea {
        min-height: 44px !important;
        padding: 8px 12px !important; 
        border-radius: 8px !important;
        font-size: 13px !important;
    }

    .admin-form__group label {
        padding-left: 12px;
        font-size: 12px;
    }
    .admin-form {
        display: grid;
        gap: 16px;
    }
}

/* ************************ */
/* RADNI NALOZI - LISTA     */
/* ************************ */

.orders-filters {
    display: flex;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 24px;
}

.orders-filter-field {
    display: flex;
    flex-direction: column;
    gap: 7px;
    min-width: 190px;
}

.orders-filter-field input,
.orders-filter-field select {
    width: 100%;
    min-height: 44px;
}

.orders-filter-submit,
.orders-today-button {
    min-height: 44px;
}

.orders-search {
    width: min(100%, 520px);
    margin-bottom: 20px;
}

.orders-search .customer-search__wrapper {
    margin-top: 7px;
}

.orders-table {
    min-width: 1080px;
}

.order-table-time {
    display: block;
    margin-top: 4px;
    color: var(--text-muted, #64748b);
    font-size: 0.82rem;
}

.order-table-meta {
    display: block;
    margin-top: 4px;
    color: var(--text-muted, #64748b);
    font-size: 0.78rem;
    line-height: 1.35;
}

.order-profit {
    color: #15803d;
}

.order-table__mobile-cell {
    display: none;
}

.order-mobile-card {
    position: relative;
    display: flex;
    align-items: stretch;
    width: 100%;
}

.order-mobile-card__main {
    display: flex;
    flex: 1;
    min-width: 0;
    flex-direction: column;
    gap: 5px;
    padding: 14px 52px 14px 14px;
    color: inherit;
    text-decoration: none;
}

.order-mobile-card__top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.order-mobile-card__number {
    display: block;
    color: var(--text-color, #0f172a);
    font-size: 0.85rem;
    font-weight: 700;
}

.order-mobile-card__time {
    display: block;
    margin-top: 3px;
    color: var(--text-muted, #64748b);
    font-size: 0.76rem;
}

.order-mobile-card__vehicle {
    display: block;
    overflow: hidden;
    margin-top: 3px;
    color: var(--text-color, #0f172a);
    font-size: 0.98rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.order-mobile-card__customer {
    color: var(--text-muted, #64748b);
    font-size: 0.85rem;
}

.order-mobile-card__description {
    display: -webkit-box;
    overflow: hidden;
    margin-top: 3px;
    color: var(--text-muted, #64748b);
    font-size: 0.82rem;
    line-height: 1.45;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.order-mobile-card__totals {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 8px;
    padding-top: 9px;
    border-top: 1px solid #e2e8f0;
}

.order-mobile-card__totals span {
    display: flex;
    flex-direction: column;
    gap: 2px;
    color: var(--text-muted, #64748b);
    font-size: 0.74rem;
}

.order-mobile-card__totals strong {
    color: var(--text-color, #0f172a);
    font-size: 0.86rem;
}

.order-mobile-card__totals .order-profit {
    color: #15803d;
}

@media (max-width: 760px) {
    .orders-filters {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 10px;
        margin-bottom: 20px;
    }

    .orders-filter-field {
        min-width: 0;
    }

    .orders-filter-submit,
    .orders-today-button {
        width: 100%;
    }

    .orders-search {
        width: 100%;
    }

    .orders-table {
        min-width: 0;
    }

    .orders-table thead {
        display: none;
    }

    .orders-table tbody {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }

    .orders-table .order-table-row {
        display: block;
        overflow: hidden;
        padding: 0;
        border: 1px solid #e2e8f0;
        border-radius: 12px;
        background: #ffffff;
    }

    .orders-table .order-table-row > td:not(
        .order-table__mobile-cell
    ) {
        display: none;
    }

    .orders-table .order-table__mobile-cell {
        display: block;
        width: 100%;
        padding: 0;
        border: 0;
    }

    .order-mobile-card .vehicle-mobile-card__edit {
        position: absolute;
        top: 52px;
        right: 12px;
    }
}

@media (max-width: 480px) {
    .orders-filters {
        grid-template-columns: 1fr;
    }

    .order-mobile-card__totals {
        grid-template-columns: 1fr 1fr;
    }
}

.orders-table {
    min-width: 1080px;
    border-collapse: collapse;
}

.orders-table th,
.orders-table td {
    vertical-align: middle;
}

.order-table-actions {
    height: 100%;
    white-space: nowrap;
}

.order-table-actions__inner {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
}








/* ******************************* */
/* RADNI NALOG - INDIVIDUALNI      */
/* ******************************* */

.order-page-heading__content {
    flex: 1 1 auto;
    min-width: 0;
}

.order-page-heading__actions {
    flex: 0 0 auto;
    width: fit-content;
    min-width: fit-content;
}

.order-page-heading__actions .button {
    width: fit-content;
    min-width: fit-content;
    white-space: nowrap;
}

.order-details-grid,
.order-party-grid {
    margin-bottom: 24px;
}

.order-description-item dd {
    white-space: normal;
    line-height: 1.65;
}

.order-status-card {
    align-self: stretch;
}

.order-status-form {
    width: 100%;
    margin-top: 20px;
}

.order-status-button {
    width: 100%;
}

.order-materials-section {
    margin-top: 24px;
}

.order-section-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 18px;
}

.order-section-heading h2 {
    margin: 0;
}

.order-material-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 32px;
    padding: 5px 12px;
    border-radius: 999px;
    background: var(--surface-muted, #f1f5f9);
    color: var(--text-muted, #64748b);
    font-size: 0.84rem;
    font-weight: 700;
    white-space: nowrap;
}

.order-materials-table-wrapper {
    width: 100%;
    overflow-x: auto;
}

.order-materials-table {
    min-width: 1050px;
}

.order-materials-table th,
.order-materials-table td {
    vertical-align: middle;
}

.order-materials-table th:nth-child(3),
.order-materials-table th:nth-child(4),
.order-materials-table th:nth-child(5),
.order-materials-table th:nth-child(6),
.order-materials-table th:nth-child(7),
.order-materials-table td:nth-child(3),
.order-materials-table td:nth-child(4),
.order-materials-table td:nth-child(5),
.order-materials-table td:nth-child(6),
.order-materials-table td:nth-child(7) {
    text-align: right;
}

.order-money-cell {
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.order-profit-cell {
    color: var(--success, #15803d);
    font-weight: 800;
}

.order-financial-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.order-financial-summary__item {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 20px;
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 14px;
    background: var(--surface, #ffffff);
}

.order-financial-summary__item span {
    color: var(--text-muted, #64748b);
    font-size: 0.87rem;
    font-weight: 700;
}

.order-financial-summary__item strong {
    color: var(--text-color, #0f172a);
    font-size: clamp(1.15rem, 2vw, 1.55rem);
    font-variant-numeric: tabular-nums;
}

.order-financial-summary__item--profit {
    border-color: #bbf7d0;
    background: #f0fdf4;
}

.order-financial-summary__item--profit strong {
    color: #15803d;
}

.order-print-actions {
    display: flex;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 28px;
}

.order-print-document {
    display: none;
}


/* ******************************* */
/* RADNI NALOG - TELEFON           */
/* ******************************* */

@media (max-width: 768px) {
    .order-page-heading {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: start;
        gap: 12px;
    }

    .order-page-heading__content {
        grid-column: 1;
        width: 100%;
        min-width: 0;
    }

    .order-page-heading__actions {
        display: flex;
        grid-column: 2;
        align-items: center;
        justify-content: flex-end;
        gap: 8px;
        width: fit-content !important;
        min-width: fit-content !important;
    }

    .order-page-heading__actions .button--back {
        flex: 0 0 40px;
        width: 40px;
        min-width: 40px;
        height: 40px;
        min-height: 40px;
        padding: 0;
    }

    .order-page-heading__actions .button--primary {
        flex: 0 0 auto;
        width: fit-content !important;
        min-width: fit-content !important;
        height: 40px;
        min-height: 40px;
        padding: 0 13px;
        font-size: 13px;
        font-weight: 700;
        line-height: 1;
    }

    .order-page-heading .customer-title-row {
        min-width: 0;
    }

    .order-page-heading .customer-title-row h1 {
        min-width: 0;
        overflow-wrap: anywhere;
    }

    .order-financial-summary {
        grid-template-columns: 1fr;
    }

    .order-print-actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .order-print-actions .button {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .order-page-heading {
        gap: 10px;
    }

    .order-page-heading .customer-title-row h1 {
        width: auto;
        font-size: 24px;
    }

    .order-section-heading {
        align-items: flex-start;
    }
}


/* ******************************* */
/* ŠTAMPA RADNOG NALOGA            */
/* ******************************* */

@media print {
    @page {
        size: A4;
        margin: 14mm;
    }

    html,
    body {
        width: 100%;
        min-width: 0;
        margin: 0;
        padding: 0;
        background: #ffffff !important;
        color: #000000 !important;
        font-family: Arial, Helvetica, sans-serif;
        font-size: 10pt;
    }

    body * {
        visibility: hidden;
    }

    .order-print-document,
    .order-print-document * {
        visibility: visible;
    }

    .order-print-document {
        position: absolute;
        top: 0;
        left: 0;
        display: block;
        width: 100%;
        color: #000000;
    }

    .order-print-header {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 24px;
        padding-bottom: 14px;
        border-bottom: 2px solid #000000;
    }

    .order-print-header h1 {
        margin: 0 0 8px;
        font-size: 20pt;
        letter-spacing: 0.04em;
    }

    .order-print-header p {
        margin: 3px 0;
    }

    .order-print-header__meta {
        text-align: right;
    }

    .order-print-columns {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }

    .order-print-block {
        margin-top: 14px;
        break-inside: avoid;
    }

    .order-print-block h2 {
        margin: 0;
        padding: 6px 8px;
        border: 1px solid #000000;
        background: #eeeeee !important;
        color: #000000;
        font-size: 11pt;
    }

    .order-print-block dl {
        display: grid;
        grid-template-columns: 1fr 1fr;
        margin: 0;
        border-right: 1px solid #000000;
        border-bottom: 1px solid #000000;
        border-left: 1px solid #000000;
    }

    .order-print-block dl > div {
        padding: 7px 8px;
        border-right: 1px solid #cccccc;
        border-bottom: 1px solid #cccccc;
    }

    .order-print-block dl > div:nth-child(even) {
        border-right: 0;
    }

    .order-print-block dl > div:nth-last-child(-n + 2) {
        border-bottom: 0;
    }

    .order-print-block dl > .order-print-block__full {
        grid-column: 1 / -1;
        border-right: 0;
    }

    .order-print-block dt {
        margin-bottom: 3px;
        color: #444444;
        font-size: 8pt;
        font-weight: 700;
        text-transform: uppercase;
    }

    .order-print-block dd {
        margin: 0;
        overflow-wrap: anywhere;
    }

    .order-print-materials table {
        width: 100%;
        border-collapse: collapse;
        font-size: 8.5pt;
    }

    .order-print-materials th,
    .order-print-materials td {
        padding: 6px;
        border: 1px solid #000000;
        text-align: left;
    }

    .order-print-materials th {
        background: #eeeeee !important;
        font-weight: 700;
    }

    .order-print-materials th:nth-child(n + 3),
    .order-print-materials td:nth-child(n + 3) {
        text-align: right;
    }

    .order-print-financials {
        width: 52%;
        margin-top: 16px;
        margin-left: auto;
        border: 1px solid #000000;
        break-inside: avoid;
    }

    .order-print-financials p {
        display: flex;
        justify-content: space-between;
        gap: 20px;
        margin: 0;
        padding: 7px 9px;
        border-bottom: 1px solid #cccccc;
    }

    .order-print-financials p:last-child {
        border-bottom: 0;
    }

    .order-print-confirmation {
        margin: 28px 0 0;
        padding: 10px;
        border: 1px solid #000000;
        font-size: 9pt;
        line-height: 1.5;
        text-align: justify;
        break-inside: avoid;
    }

    .order-print-signatures {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 60px;
        margin-top: 52px;
        break-inside: avoid;
    }

    .order-print-signatures > div {
        text-align: center;
    }

    .order-print-signatures span {
        display: block;
        margin-bottom: 34px;
        font-size: 9pt;
    }

    .order-signature-line {
        border-top: 1px solid #000000;
    }

    body.print-order-without-finances .order-financial-column,
    body.print-order-without-finances .order-financial-section {
        display: none !important;
    }

    body.print-order-without-finances
    .order-print-materials
    th:nth-child(3),
    body.print-order-without-finances
    .order-print-materials
    td:nth-child(3) {
        text-align: right;
    }
}


/* ******************************** */
/* MATERIJALI RADNOG NALOGA          */
/* ******************************** */

.order-materials-section {
    width: 100%;
    margin-top: 28px;
}

.order-materials-table-wrapper {
    width: 100%;
    overflow-x: auto;
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 14px;
    background: var(--surface, #ffffff);
}

.order-materials-table {
    width: 100%;
    min-width: 1040px;
    margin: 0;
    border-collapse: collapse;
    table-layout: auto;
}

.order-materials-table thead {
    background: var(--surface-muted, #f8fafc);
}

.order-materials-table th {
    padding: 14px 16px;
    border: 0;
    border-bottom: 1px solid var(--border-color, #e2e8f0);
    color: var(--text-muted, #64748b);
    font-size: 0.76rem;
    font-weight: 800;
    line-height: 1.3;
    text-align: left;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.order-materials-table td {
    height: auto;
    padding: 16px;
    border: 0;
    border-bottom: 1px solid var(--border-color, #e2e8f0);
    background: transparent;
    color: var(--text-color, #0f172a);
    font-size: 0.92rem;
    line-height: 1.45;
    vertical-align: middle;
}

.order-materials-table tbody tr:last-child td {
    border-bottom: 0;
}

.order-materials-table tbody tr:hover td {
    background: var(--surface-muted, #f8fafc);
}

.order-materials-table th:first-child,
.order-materials-table td:first-child {
    min-width: 210px;
}

.order-materials-table th:nth-child(2),
.order-materials-table td:nth-child(2) {
    min-width: 150px;
}

.order-materials-table th:nth-child(3),
.order-materials-table td:nth-child(3),
.order-materials-table th:nth-child(4),
.order-materials-table td:nth-child(4),
.order-materials-table th:nth-child(6),
.order-materials-table td:nth-child(6),
.order-materials-table th:nth-child(7),
.order-materials-table td:nth-child(7) {
    min-width: 140px;
    text-align: right;
    white-space: nowrap;
}

.order-materials-table th:nth-child(5),
.order-materials-table td:nth-child(5) {
    min-width: 90px;
    text-align: right;
    white-space: nowrap;
}

.order-materials-table td:first-child strong {
    display: block;
    color: var(--text-color, #0f172a);
    font-weight: 800;
    overflow-wrap: anywhere;
}

.order-money-cell {
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.order-profit-cell {
    color: var(--success, #15803d) !important;
    font-weight: 800;
}


/* ******************************** */
/* MATERIJALI - TELEFON              */
/* ******************************** */

@media (max-width: 768px) {
    .order-materials-section {
        margin-top: 22px;
    }

    .order-materials-table-wrapper {
        overflow: visible;
        border: 0;
        border-radius: 0;
        background: transparent;
    }

    .order-materials-table {
        display: block;
        width: 100%;
        min-width: 0 !important;
        border: 0;
    }

    .order-materials-table thead {
        display: none;
    }

    .order-materials-table tbody {
        display: grid;
        width: 100%;
        gap: 14px;
    }

    .order-materials-table tr {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        width: 100%;
        overflow: hidden;
        border: 1px solid var(--border-color, #e2e8f0);
        border-radius: 14px;
        background: var(--surface, #ffffff);
        box-shadow: 0 3px 12px rgb(15 23 42 / 5%);
    }

    .order-materials-table td {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-start;
        min-width: 0 !important;
        height: auto !important;
        padding: 13px 14px;
        border: 0;
        border-right: 1px solid var(--border-color, #e2e8f0);
        border-bottom: 1px solid var(--border-color, #e2e8f0);
        background: transparent !important;
        text-align: left !important;
        white-space: normal !important;
    }

    .order-materials-table td::before {
        display: block;
        margin-bottom: 5px;
        color: var(--text-muted, #64748b);
        content: attr(data-label);
        font-size: 0.69rem;
        font-weight: 800;
        line-height: 1.2;
        text-transform: uppercase;
        letter-spacing: 0.04em;
    }

    /* Naziv materijala */

    .order-materials-table td:nth-child(1) {
        grid-column: 1 / -1;
        padding: 16px 14px;
        border-right: 0;
    }

    .order-materials-table td:nth-child(1) strong {
        font-size: 1rem;
        line-height: 1.35;
    }

    /* Dobavljač preko cijele širine */

    .order-materials-table td:nth-child(2) {
        grid-column: 1 / -1;
        border-right: 0;
    }

    /* Lijeva kolona */

    .order-materials-table td:nth-child(3),
    .order-materials-table td:nth-child(5),
    .order-materials-table td:nth-child(7) {
        border-right: 1px solid var(--border-color, #e2e8f0);
    }

    /* Desna kolona */

    .order-materials-table td:nth-child(4),
    .order-materials-table td:nth-child(6) {
        border-right: 0;
    }

    /* Zadnji red kartice */

    .order-materials-table td:nth-child(7) {
        grid-column: 1 / -1;
        border-right: 0;
        border-bottom: 0;
        background: #f0fdf4 !important;
    }

    .order-materials-table td:nth-child(7)::before {
        color: #15803d;
    }

    .order-materials-table td:nth-child(6) {
        border-bottom: 1px solid var(--border-color, #e2e8f0);
    }

    .order-money-cell {
        font-size: 0.92rem;
    }

    /* Sakrij zaradu pojedinačnog materijala na telefonu */
        .order-materials-table td:nth-child(7) {
            display: none;
        }

        /* Ukloni donju ivicu sa posljednja dva vidljiva polja */
        .order-materials-table td:nth-child(5),
        .order-materials-table td:nth-child(6) {
            border-bottom: 0;
        }
}

@media (max-width: 390px) {
    .order-materials-table td {
        padding: 12px;
    }
}


/*
 * DODATAK ZA style.css
 *
 * Ako create-order.php već izgleda ispravno i u style.css već postoje klase:
 * .order-combobox, .order-suggestions, .order-suggestion i
 * .order-suggestions__empty, nije potrebno dodavati ništa.
 *
 * U suprotnom dodaj ovaj blok na kraj style.css.
 */

.order-combobox {
    position: relative;
}

.order-suggestions {
    position: absolute;
    z-index: 40;
    top: calc(100% + 6px);
    right: 0;
    left: 0;
    max-height: 280px;
    overflow-y: auto;
    padding: 6px;
    border: 1px solid var(--border-color, #dfe3e8);
    border-radius: 12px;
    background: var(--surface, #ffffff);
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.14);
}

.order-suggestions[hidden] {
    display: none !important;
}

.order-suggestion {
    display: block;
    width: 100%;
    padding: 11px 12px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: inherit;
    font: inherit;
    line-height: 1.35;
    text-align: left;
    cursor: pointer;
}

.order-suggestion:hover,
.order-suggestion.is-active {
    background: var(--surface-soft, #f1f5f9);
}

.order-suggestions__empty {
    padding: 11px 12px;
    color: var(--text-muted, #64748b);
    font-size: 14px;
}




/* =========================================================
   TROŠKOVI I PRIHODI
   Sve klase sadržaja stranice imaju expenses- prefiks.
   Naslov i standardna dugmad namjerno koriste postojeći stil.
   ========================================================= */

.expenses-page-heading {
    align-items: flex-start;
}

.expenses-heading-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 10px;
}

.expenses-page {
    --expenses-border: #e2e8f0;
    --expenses-soft: #f8fafc;
    --expenses-text: #0f172a;
    --expenses-muted: #64748b;
    --expenses-primary: #2563eb;
    --expenses-primary-soft: #eff6ff;
    --expenses-danger: #dc2626;
    --expenses-danger-soft: #fef2f2;
    --expenses-income: #15803d;
    --expenses-income-soft: #f0fdf4;
    display: grid;
    gap: 22px;
}

.expenses-alert {
    padding: 14px 16px;
    border: 1px solid;
    border-radius: 12px;
    font-size: 0.94rem;
    font-weight: 600;
    line-height: 1.5;
}

.expenses-alert--success {
    color: #166534;
    background: #f0fdf4;
    border-color: #bbf7d0;
}

.expenses-alert--error {
    color: #991b1b;
    background: #fef2f2;
    border-color: #fecaca;
}

.expenses-period {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    padding: 20px;
    background: #fff;
    border: 1px solid var(--expenses-border);
    border-radius: 16px;
    box-shadow: 0 4px 18px rgba(15, 23, 42, 0.04);
}

.expenses-period__intro {
    display: grid;
    gap: 5px;
    min-width: 180px;
}

.expenses-period__label {
    color: var(--expenses-muted);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.expenses-period__intro strong {
    color: var(--expenses-text);
    font-size: 1.18rem;
}

.expenses-period__form {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    gap: 12px;
}

.expenses-field {
    display: grid;
    gap: 7px;
    min-width: 170px;
}

.expenses-field label {
    color: #334155;
    font-size: 0.84rem;
    font-weight: 700;
}

.expenses-field input,
.expenses-field select {
    width: 100%;
    height: 44px;
    padding: 0 12px;
    color: var(--expenses-text);
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    outline: none;
    font: inherit;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.expenses-field input:focus,
.expenses-field select:focus {
    border-color: var(--expenses-primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.expenses-period__submit {
    min-height: 44px;
}

.expenses-panel {
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--expenses-border);
    border-radius: 16px;
    box-shadow: 0 4px 18px rgba(15, 23, 42, 0.04);
}

.expenses-panel__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 20px 22px;
    border-bottom: 1px solid var(--expenses-border);
}

.expenses-panel__header > div {
    display: grid;
    gap: 5px;
}

.expenses-panel__header h2 {
    margin: 0;
    color: var(--expenses-text);
    font-size: 1.22rem;
    line-height: 1.25;
}

.expenses-panel__eyebrow {
    color: var(--expenses-primary);
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.expenses-panel__eyebrow--income {
    color: var(--expenses-income);
}

.expenses-panel__period,
.expenses-count {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 5px 11px;
    color: #1d4ed8;
    background: var(--expenses-primary-soft);
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 700;
    white-space: nowrap;
}

.expenses-count--income {
    color: var(--expenses-income);
    background: var(--expenses-income-soft);
}

.expenses-table-wrap {
    width: 100%;
    overflow-x: auto;
}

.expenses-table {
    width: 100%;
    border-collapse: collapse;
    color: var(--expenses-text);
    table-layout: fixed;
}

.expenses-table th {
    padding: 12px 18px;
    color: #475569;
    background: var(--expenses-soft);
    border-bottom: 1px solid var(--expenses-border);
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.045em;
    text-align: left;
    text-transform: uppercase;
}

.expenses-table td {
    height: 64px;
    padding: 10px 18px;
    border-bottom: 1px solid #edf2f7;
    font-size: 0.92rem;
    line-height: 1.45;
    vertical-align: middle;
}

.expenses-table tbody tr:last-child td {
    border-bottom: 0;
}

.expenses-table tbody tr {
    transition: background-color 0.18s ease;
}

.expenses-table tbody tr:hover {
    background: #fbfdff;
}

.expenses-table--fixed th:first-child,
.expenses-table--fixed td:first-child {
    width: 62%;
}

.expenses-table--fixed th:last-child,
.expenses-table--fixed td:last-child {
    width: 38%;
}

.expenses-table--list th:nth-child(1) {
    width: 25%;
}

.expenses-table--list th:nth-child(2) {
    width: 43%;
}

.expenses-table--list th:nth-child(3) {
    width: 18%;
}

.expenses-table--list th:nth-child(4) {
    width: 14%;
}

.expenses-table__name {
    color: var(--expenses-text);
    font-weight: 700;
}

.expenses-table__note {
    color: var(--expenses-muted);
    overflow-wrap: anywhere;
}

.expenses-table__actions-heading,
.expenses-table__actions {
    text-align: right !important;
}

.expenses-table__actions form {
    display: inline-flex;
    margin: 0;
}

.expenses-amount-input {
    position: relative;
    width: min(100%, 230px);
}

.expenses-amount-input input {
    width: 100%;
    height: 42px;
    padding: 0 48px 0 12px;
    color: var(--expenses-text);
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 9px;
    outline: none;
    font: inherit;
    font-weight: 700;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.expenses-amount-input input:focus {
    border-color: var(--expenses-primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.expenses-amount-input > span {
    position: absolute;
    top: 50%;
    right: 12px;
    color: var(--expenses-muted);
    font-size: 0.78rem;
    font-weight: 800;
    transform: translateY(-50%);
    pointer-events: none;
}

.expenses-value {
    display: inline-flex;
    align-items: center;
    padding: 5px 9px;
    border-radius: 8px;
    font-size: 0.88rem;
    white-space: nowrap;
}

.expenses-value--expense {
    color: #b91c1c;
    background: var(--expenses-danger-soft);
}

.expenses-value--income {
    color: var(--expenses-income);
    background: var(--expenses-income-soft);
}

.expenses-delete {
    min-height: 34px;
    padding: 6px 11px;
    color: var(--expenses-danger);
    background: #fff;
    border: 1px solid #fecaca;
    border-radius: 8px;
    cursor: pointer;
    font: inherit;
    font-size: 0.82rem;
    font-weight: 700;
    transition: color 0.18s ease, background-color 0.18s ease, border-color 0.18s ease;
}

.expenses-delete:hover {
    color: #fff;
    background: var(--expenses-danger);
    border-color: var(--expenses-danger);
}

.expenses-panel__footer {
    display: flex;
    justify-content: flex-end;
    padding: 16px 22px;
    background: var(--expenses-soft);
    border-top: 1px solid var(--expenses-border);
}

.expenses-empty {
    display: grid;
    justify-items: center;
    padding: 42px 20px;
    text-align: center;
}

.expenses-empty__icon {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    margin-bottom: 12px;
    color: var(--expenses-primary);
    background: var(--expenses-primary-soft);
    border-radius: 50%;
    font-size: 1.3rem;
    font-weight: 500;
}

.expenses-empty__icon--income {
    color: var(--expenses-income);
    background: var(--expenses-income-soft);
}

.expenses-empty h3 {
    margin: 0 0 6px;
    color: var(--expenses-text);
    font-size: 1rem;
}

.expenses-empty p {
    max-width: 460px;
    margin: 0;
    color: var(--expenses-muted);
    font-size: 0.9rem;
    line-height: 1.5;
}

@media (max-width: 900px) {
    .expenses-period {
        align-items: stretch;
        flex-direction: column;
    }

    .expenses-period__form {
        justify-content: flex-start;
    }

    .expenses-table--list th:nth-child(1) {
        width: 27%;
    }

    .expenses-table--list th:nth-child(2) {
        width: 35%;
    }

    .expenses-table--list th:nth-child(3) {
        width: 22%;
    }

    .expenses-table--list th:nth-child(4) {
        width: 16%;
    }
}

@media (max-width: 760px) {
    .expenses-page-heading {
        gap: 14px;
    }

    .expenses-heading-actions {
        justify-content: flex-start;
        width: 100%;
    }

    .expenses-heading-actions .button {
        flex: 1 1 145px;
        justify-content: center;
    }

    .expenses-page {
        gap: 16px;
    }

    .expenses-period {
        gap: 16px;
        padding: 16px;
        border-radius: 13px;
    }

    .expenses-period__form {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 0.82fr);
        gap: 10px;
    }

    .expenses-field {
        min-width: 0;
    }

    .expenses-period__submit {
        grid-column: 1 / -1;
        width: 100%;
    }

    .expenses-panel {
        border-radius: 13px;
    }

    .expenses-panel__header {
        align-items: flex-start;
        padding: 16px;
    }

    .expenses-panel__header h2 {
        font-size: 1.08rem;
    }

    .expenses-panel__period,
    .expenses-count {
        min-height: 28px;
        padding: 4px 9px;
        font-size: 0.72rem;
    }

    .expenses-table-wrap {
        overflow: visible;
    }

    .expenses-table,
    .expenses-table tbody,
    .expenses-table tr,
    .expenses-table td {
        display: block;
        width: 100%;
    }

    .expenses-table {
        table-layout: auto;
    }

    .expenses-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
        clip-path: inset(50%);
    }

    .expenses-table tbody {
        display: grid;
        gap: 0;
    }

    .expenses-table tr {
        padding: 14px 16px;
        border-bottom: 1px solid var(--expenses-border);
    }

    .expenses-table tbody tr:last-child {
        border-bottom: 0;
    }

    .expenses-table td {
        display: grid;
        grid-template-columns: minmax(105px, 0.8fr) minmax(0, 1.4fr);
        align-items: center;
        gap: 12px;
        height: auto;
        min-height: 38px;
        padding: 4px 0;
        border: 0;
        text-align: right;
    }

    .expenses-table td::before {
        content: attr(data-label);
        color: var(--expenses-muted);
        font-size: 0.74rem;
        font-weight: 800;
        letter-spacing: 0.025em;
        text-align: left;
        text-transform: uppercase;
    }

    .expenses-table tbody tr:hover {
        background: transparent;
    }

    .expenses-table--fixed tr {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        align-items: center;
        gap: 12px;
    }

    .expenses-table--fixed td {
        display: block;
        width: 100% !important;
        min-width: 0;
        padding: 0;
        text-align: left;
    }

    .expenses-table--fixed td::before {
        display: none;
    }

    .expenses-amount-input {
        width: 100%;
        max-width: none;
    }

    .expenses-amount-input input {
        display: block;
        width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    .expenses-table__note {
        text-align: right;
    }

    .expenses-table__actions {
        text-align: right !important;
    }

    .expenses-panel__footer {
        padding: 14px 16px;
    }

    .expenses-panel__footer .button {
        width: 100%;
        justify-content: center;
    }

    .expenses-empty {
        padding: 34px 18px;
    }
}

@media (max-width: 430px) {
    .expenses-heading-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .expenses-heading-actions .button {
        width: 100%;
        padding-inline: 10px;
        font-size: 0.84rem;
    }

    .expenses-panel__header {
        gap: 10px;
    }

    .expenses-table--fixed tr {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}



/* =========================================================
   IZVJEŠTAJI
   Dodati na kraj css/style.css.
   ========================================================= */

.reports-page {
    --reports-border: #e2e8f0;
    --reports-soft: #f8fafc;
    --reports-text: #0f172a;
    --reports-muted: #64748b;
    --reports-primary: #2563eb;
    --reports-income: #15803d;
    --reports-income-soft: #f0fdf4;
    --reports-expense: #b91c1c;
    --reports-expense-soft: #fef2f2;
    display: grid;
    gap: 22px;
}

.reports-period {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    padding: 20px;
    background: #fff;
    border: 1px solid var(--reports-border);
    border-radius: 16px;
    box-shadow: 0 4px 18px rgba(15, 23, 42, 0.04);
}

.reports-period__intro {
    display: grid;
    gap: 5px;
    min-width: 180px;
}

.reports-period__label {
    color: var(--reports-muted);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.reports-period__intro strong {
    color: var(--reports-text);
    font-size: 1.18rem;
}

.reports-period__form {
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    gap: 12px;
}

.reports-field {
    display: grid;
    gap: 7px;
    min-width: 170px;
}

.reports-field label {
    color: #334155;
    font-size: 0.84rem;
    font-weight: 700;
}

.reports-field input,
.reports-field select {
    width: 100%;
    height: 44px;
    padding: 0 12px;
    color: var(--reports-text);
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    outline: none;
    font: inherit;
}

.reports-field input:focus,
.reports-field select:focus {
    border-color: var(--reports-primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.reports-period__submit {
    min-height: 44px;
}

.reports-panel {
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--reports-border);
    border-radius: 16px;
    box-shadow: 0 4px 18px rgba(15, 23, 42, 0.04);
}

.reports-panel__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 22px;
    border-bottom: 1px solid var(--reports-border);
}

.reports-panel__header > div {
    display: grid;
    gap: 5px;
}

.reports-panel__header h2 {
    margin: 0;
    color: var(--reports-text);
    font-size: 1.22rem;
}

.reports-panel__eyebrow {
    color: var(--reports-primary);
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.reports-panel__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
}

.reports-action-button {
    min-height: 42px;
    white-space: nowrap;
}

.reports-table-wrap {
    width: 100%;
    overflow-x: auto;
}

.reports-table {
    width: 100%;
    color: var(--reports-text);
    border-collapse: collapse;
    table-layout: fixed;
}

.reports-table thead th {
    padding: 12px 18px;
    color: #475569;
    background: var(--reports-soft);
    border-bottom: 1px solid var(--reports-border);
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.045em;
    text-align: left;
    text-transform: uppercase;
}

.reports-table thead th:nth-child(1) {
    width: 38%;
}

.reports-table thead th:nth-child(2) {
    width: 37%;
}

.reports-table thead th:nth-child(3) {
    width: 25%;
}

.reports-table td,
.reports-table tfoot th {
    height: 62px;
    padding: 11px 18px;
    border-bottom: 1px solid #edf2f7;
    font-size: 0.92rem;
    line-height: 1.45;
    vertical-align: middle;
}

.reports-table td:nth-child(2) {
    color: var(--reports-muted);
}

.reports-table__amount {
    text-align: right !important;
}

.reports-table__summary {
    background: #fbfdff;
}

.reports-table__summary td {
    height: 66px;
}

.reports-table__section-row th {
    padding: 13px 18px;
    color: #475569;
    background: var(--reports-soft);
    border-top: 1px solid var(--reports-border);
    border-bottom: 1px solid var(--reports-border);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-align: left;
    text-transform: uppercase;
}

.reports-value {
    display: inline-flex;
    align-items: center;
    padding: 5px 9px;
    border-radius: 8px;
    font-size: 0.88rem;
    white-space: nowrap;
}

.reports-value--income {
    color: var(--reports-income);
    background: var(--reports-income-soft);
}

.reports-value--expense {
    color: var(--reports-expense);
    background: var(--reports-expense-soft);
}

.reports-empty {
    height: auto !important;
    padding: 34px 18px !important;
    color: var(--reports-muted);
    text-align: center;
}

.reports-table tfoot {
    background: #0f172a;
}

.reports-table tfoot th,
.reports-table tfoot td {
    height: 70px;
    color: #fff;
    border: 0;
    font-size: 1rem;
}

.reports-table tfoot th {
    text-align: left;
}

.reports-total {
    font-size: 1.12rem;
    white-space: nowrap;
}

.reports-total--positive {
    color: #86efac;
}

.reports-total--negative {
    color: #fca5a5;
}

@media (max-width: 900px) {
    .reports-period {
        align-items: stretch;
        flex-direction: column;
    }

    .reports-period__form {
        justify-content: flex-start;
    }
}

@media (max-width: 760px) {
    .reports-page {
        gap: 16px;
    }

    .reports-period {
        gap: 16px;
        padding: 16px;
        border-radius: 13px;
    }

    .reports-period__form {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 0.82fr);
        gap: 10px;
    }

    .reports-field {
        min-width: 0;
    }

    .reports-period__submit {
        grid-column: 1 / -1;
        width: 100%;
    }

    .reports-panel {
        border-radius: 13px;
    }

    .reports-panel__header {
        align-items: stretch;
        flex-direction: column;
        gap: 14px;
        padding: 16px;
    }

    .reports-panel__actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .reports-action-button {
        width: 100%;
        padding-right: 10px;
        padding-left: 10px;
        text-align: center;
    }

    .reports-panel__header h2 {
        font-size: 1.08rem;
    }

    .reports-table-wrap {
        overflow: visible;
    }

    .reports-table,
    .reports-table tbody,
    .reports-table tr,
    .reports-table td {
        display: block;
        width: 100%;
    }

    .reports-table {
        table-layout: auto;
    }

    .reports-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
        clip-path: inset(50%);
    }

    .reports-table tbody {
        display: grid;
    }

    .reports-table tbody tr:not(.reports-table__section-row) {
        padding: 12px 16px;
        border-bottom: 1px solid var(--reports-border);
    }

    .reports-table td {
        display: grid;
        grid-template-columns: minmax(115px, 0.9fr) minmax(0, 1.1fr);
        align-items: center;
        gap: 12px;
        height: auto;
        min-height: 36px;
        padding: 4px 0;
        border: 0;
        text-align: right;
    }

    .reports-table td::before {
        content: attr(data-label);
        color: var(--reports-muted);
        font-size: 0.73rem;
        font-weight: 800;
        letter-spacing: 0.025em;
        text-align: left;
        text-transform: uppercase;
    }

    .reports-table__section-row {
        display: table-row;
    }

    .reports-table__section-row th {
        display: table-cell;
        width: 100%;
        padding: 12px 16px;
    }

    .reports-empty {
        display: block !important;
        text-align: center !important;
    }

    .reports-empty::before {
        display: none;
    }

    .reports-table tfoot,
    .reports-table tfoot tr {
        display: grid;
        width: 100%;
    }

    .reports-table tfoot tr {
        grid-template-columns: 1fr auto;
        align-items: center;
        padding: 17px 16px;
    }

    .reports-table tfoot th,
    .reports-table tfoot td {
        display: block;
        width: auto;
        height: auto;
        padding: 0;
    }
}

@media print {
    @page {
        size: A4 portrait;
        margin: 14mm;
    }

    body {
        color: #000 !important;
        background: #fff !important;
    }

    .sidebar,
    .main-shell > header,
    .main-shell > footer,
    .reports-page-heading,
    .reports-period,
    .reports-panel__actions {
        display: none !important;
    }

    .app-layout,
    .main-shell,
    .main-content,
    .reports-page {
        display: block !important;
        width: 100% !important;
        min-width: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .reports-panel {
        overflow: visible;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }

    .reports-panel__header {
        display: block;
        padding: 0 0 14px;
        border-bottom: 2px solid #0f172a;
    }

    .reports-panel__header::before {
        content: "Finansijski izvještaj";
        display: block;
        margin-bottom: 5px;
        color: #000;
        font-size: 20pt;
        font-weight: 800;
    }

    .reports-panel__eyebrow {
        display: none;
    }

    .reports-panel__header h2 {
        color: #334155;
        font-size: 12pt;
    }

    .reports-table-wrap {
        overflow: visible;
    }

    .reports-table {
        display: table !important;
        width: 100% !important;
        color: #000;
        table-layout: fixed;
    }

    .reports-table thead {
        position: static;
        display: table-header-group !important;
        width: auto;
        height: auto;
        overflow: visible;
        clip: auto;
        white-space: normal;
        clip-path: none;
    }

    .reports-table tbody {
        display: table-row-group !important;
    }

    .reports-table tfoot {
        display: table-footer-group !important;
    }

    .reports-table tr,
    .reports-table tbody tr:not(.reports-table__section-row),
    .reports-table tfoot tr {
        display: table-row !important;
        padding: 0;
        break-inside: avoid;
    }

    .reports-table th,
    .reports-table td,
    .reports-table tfoot th,
    .reports-table tfoot td,
    .reports-table__section-row th {
        display: table-cell !important;
        width: auto !important;
        height: auto;
        min-height: 0;
        padding: 8px 10px;
        color: #000 !important;
        background: transparent !important;
        border-bottom: 1px solid #cbd5e1;
        font-size: 9pt;
    }

    .reports-table td::before {
        display: none !important;
    }

    .reports-value {
        padding: 0;
        color: #000 !important;
        background: transparent !important;
    }

    .reports-table tfoot th,
    .reports-table tfoot td {
        padding-top: 11px;
        padding-bottom: 11px;
        color: #fff !important;
        background: #0f172a !important;
        border: 0;
    }

    .reports-total {
        color: #fff !important;
    }
}



/* ************************ */
/* DOBAVLJAČI               */
/* ************************ */

.suppliers-layout {
    display: grid;
    gap: 24px;
}

.suppliers-filters {
    display: flex;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 24px;
    padding: 18px;
    background: #ffffff;
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 14px;
}

.suppliers-filter-field {
    display: flex;
    flex-direction: column;
    gap: 7px;
    min-width: 180px;
}

.suppliers-filter-field[hidden] {
    display: none;
}

.suppliers-filter-field label {
    color: var(--text-color, #0f172a);
    font-size: 0.86rem;
    font-weight: 600;
}

.suppliers-filter-field select {
    width: 100%;
    min-height: 44px;
    padding: 9px 36px 9px 12px;
    color: var(--text-color, #0f172a);
    background-color: #ffffff;
    border: 1px solid var(--border-color, #cbd5e1);
    border-radius: 10px;
    outline: none;
}

.suppliers-filter-field select:focus {
    border-color: var(--primary-color, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.suppliers-filter-submit {
    min-height: 44px;
}

.suppliers-panel {
    overflow: hidden;
    background: #ffffff;
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 16px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05);
}

.suppliers-panel__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    padding: 22px 24px;
    border-bottom: 1px solid var(--border-color, #e2e8f0);
}

.suppliers-panel__header h2 {
    margin: 0;
    color: var(--text-color, #0f172a);
    font-size: 1.08rem;
}

.suppliers-panel__header p {
    margin: 6px 0 0;
    color: var(--text-muted, #64748b);
    font-size: 0.9rem;
    line-height: 1.5;
}

.suppliers-count {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    min-height: 34px;
    padding: 4px 10px;
    color: var(--primary-color, #2563eb);
    background: #eff6ff;
    border-radius: 999px;
    font-size: 0.88rem;
    font-weight: 700;
}

.suppliers-table-wrap {
    width: 100%;
    overflow-x: auto;
}

.suppliers-table {
    width: 100%;
    border-collapse: collapse;
}

.suppliers-table th,
.suppliers-table td {
    padding: 17px 24px;
    border-bottom: 1px solid var(--border-color, #e2e8f0);
    text-align: left;
    vertical-align: middle;
}

.suppliers-table th {
    color: var(--text-muted, #64748b);
    background: #f8fafc;
    font-size: 0.77rem;
    font-weight: 700;
    letter-spacing: 0.055em;
    text-transform: uppercase;
}

.suppliers-table tbody tr:last-child td {
    border-bottom: 0;
}

.suppliers-table tbody tr:hover {
    background: #fbfdff;
}

.suppliers-table__amount {
    text-align: right !important;
    white-space: nowrap;
}

.suppliers-table td.suppliers-table__amount {
    color: var(--text-color, #0f172a);
    font-variant-numeric: tabular-nums;
    font-weight: 700;
}

.suppliers-empty {
    padding: 44px 24px;
    text-align: center;
}

.suppliers-empty h3 {
    margin: 0 0 7px;
    color: var(--text-color, #0f172a);
}

.suppliers-empty p {
    margin: 0;
    color: var(--text-muted, #64748b);
}

.suppliers-panel--form {
    max-width: 720px;
}

.suppliers-form {
    display: flex;
    align-items: flex-end;
    gap: 14px;
    padding: 24px;
}

.suppliers-form__field {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.suppliers-form__field label {
    color: var(--text-color, #0f172a);
    font-size: 0.9rem;
    font-weight: 600;
}

.suppliers-form__field input {
    width: 100%;
    min-height: 46px;
    padding: 10px 13px;
    color: var(--text-color, #0f172a);
    background: #ffffff;
    border: 1px solid var(--border-color, #cbd5e1);
    border-radius: 10px;
    outline: none;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.suppliers-form__field input:focus {
    border-color: var(--primary-color, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.suppliers-form .button {
    flex: 0 0 auto;
    min-height: 46px;
}

@media (max-width: 760px) {
    .suppliers-filters {
        align-items: stretch;
        gap: 12px;
        margin-bottom: 18px;
        padding: 16px;
    }

    .suppliers-filter-field {
        width: 100%;
        min-width: 0;
    }

    .suppliers-filter-submit {
        width: fit-content;
    }

    .suppliers-layout {
        gap: 18px;
    }

    .suppliers-panel {
        border-radius: 13px;
    }

    .suppliers-panel__header {
        padding: 18px;
    }

    .suppliers-table thead {
        display: none;
    }

    .suppliers-table,
    .suppliers-table tbody,
    .suppliers-table tr,
    .suppliers-table td {
        display: block;
        width: 100%;
    }

    .suppliers-table tr {
        padding: 16px 18px;
        border-bottom: 1px solid var(--border-color, #e2e8f0);
    }

    .suppliers-table tbody tr:last-child {
        border-bottom: 0;
    }

    .suppliers-table td {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 18px;
        padding: 0;
        border: 0;
        text-align: right;
    }

    .suppliers-table td + td {
        margin-top: 11px;
        padding-top: 11px;
        border-top: 1px dashed var(--border-color, #e2e8f0);
    }

    .suppliers-table td::before {
        content: attr(data-label);
        flex: 0 0 auto;
        color: var(--text-muted, #64748b);
        font-size: 0.78rem;
        font-weight: 600;
        text-align: left;
    }

    .suppliers-table__amount {
        text-align: right !important;
    }

    .suppliers-form {
        align-items: stretch;
        flex-direction: column;
        padding: 18px;
    }

    .suppliers-form .button {
        width: fit-content;
    }
}


/* ************************ */
/* VOZILO - RADNI NALOZI    */
/* ************************ */

.vehicle-page-heading__content {
    flex: 1 1 auto;
    min-width: 0;
}

.vehicle-page-heading__actions {
    flex: 0 0 auto;
    width: fit-content;
    min-width: fit-content;
}

.vehicle-page-heading__actions .vehicle-header-edit {
    display: inline-flex;
    flex: 0 0 auto;
    width: fit-content;
    min-width: fit-content;
    white-space: nowrap;
}

.vehicle-orders-section {
    margin-top: 28px;
}

.vehicle-orders-section__header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.vehicle-orders-section__header h2 {
    margin: 0;
}

.vehicle-orders-count {
    color: var(--text-muted, #64748b);
    font-size: 0.9rem;
    font-weight: 700;
}

.vehicle-orders-table {
    min-width: 940px;
}

.vehicle-orders-table .order-description-cell {
    max-width: 280px;
}

.vehicle-orders-table .order-description-text {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.vehicle-orders-empty {
    padding: 32px 24px;
    border: 1px dashed var(--border-color, #d7dee8);
    border-radius: 14px;
    background: var(--surface, #fff);
    text-align: center;
}

.vehicle-orders-empty h3 {
    margin: 0 0 8px;
}

.vehicle-orders-empty p {
    margin: 0;
    color: var(--text-muted, #64748b);
}

.vehicle-orders-table .order-table__mobile-cell {
    display: none;
}

@media (max-width: 760px) {
    .vehicle-page-heading {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: start;
        gap: 12px;
    }

    .vehicle-page-heading__content {
        grid-column: 1;
        width: 100%;
        min-width: 0;
    }

    .vehicle-page-heading__actions {
        display: flex;
        grid-column: 2;
        align-items: center;
        justify-content: flex-end;
        gap: 8px;
        width: fit-content !important;
        min-width: fit-content !important;
    }

    .vehicle-page-heading__actions .button--back {
        flex: 0 0 40px;
        width: 40px;
        min-width: 40px;
        height: 40px;
        min-height: 40px;
        padding: 0;
    }

    .vehicle-page-heading__actions .vehicle-header-edit {
        flex: 0 0 auto !important;
        width: fit-content !important;
        min-width: fit-content !important;
        height: 40px;
        min-height: 40px;
        padding: 0 13px;
        font-size: 13px;
        line-height: 1;
    }

    .vehicle-page-heading .customer-title-row,
    .vehicle-page-heading .customer-title-row h1 {
        min-width: 0;
    }

    .vehicle-page-heading .customer-title-row h1 {
        overflow-wrap: anywhere;
    }

    .vehicle-orders-section {
        margin-top: 22px;
    }

    .vehicle-orders-section__header {
        align-items: flex-start;
        margin-bottom: 14px;
    }

    .vehicle-orders-table {
        min-width: 0;
    }

    .vehicle-orders-table thead,
    .vehicle-orders-table
        tbody
        > tr
        > td:not(.order-table__mobile-cell) {
        display: none;
    }

    .vehicle-orders-table,
    .vehicle-orders-table tbody,
    .vehicle-orders-table tr,
    .vehicle-orders-table .order-table__mobile-cell {
        display: block;
        width: 100%;
    }

    .vehicle-orders-table .order-table-row {
        margin-bottom: 12px;
        border: 0;
    }

    .vehicle-orders-table .order-table__mobile-cell {
        padding: 0;
        border: 0;
    }

    .vehicle-orders-table .order-mobile-card {
        width: 100%;
    }

    .vehicle-orders-table .order-mobile-card__description {
        display: -webkit-box;
        overflow: hidden;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 3;
        line-clamp: 3;
    }

    .vehicle-orders-empty {
        padding: 26px 18px;
    }
}

@media (max-width: 480px) {
    .vehicle-page-heading {
        gap: 10px;
    }

    .vehicle-page-heading .customer-title-row h1 {
        width: auto;
        font-size: 24px;
    }
}



/* ************************ */
/* KLIJENT - RADNI NALOZI   */
/* ************************ */

.customer-orders-section {
    margin-top: 28px;
}

.customer-orders-section__header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.customer-orders-section__header h2 {
    margin: 0;
}

.customer-orders-count {
    color: var(--text-muted, #64748b);
    font-size: 0.9rem;
    font-weight: 700;
    white-space: nowrap;
}

.customer-orders-table {
    min-width: 1120px;
}

.customer-orders-table .order-description-cell {
    max-width: 260px;
}

.customer-orders-table .order-description-text {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.customer-orders-empty {
    padding: 32px 24px;
    border: 1px dashed var(--border-color, #d7dee8);
    border-radius: 14px;
    background: var(--surface, #fff);
    text-align: center;
}

.customer-orders-empty h3 {
    margin: 0 0 8px;
}

.customer-orders-empty p {
    margin: 0;
    color: var(--text-muted, #64748b);
}

.customer-orders-table .order-table__mobile-cell {
    display: none;
}

@media (max-width: 760px) {
    .customer-orders-section {
        margin-top: 22px;
    }

    .customer-orders-section__header {
        align-items: flex-start;
        margin-bottom: 14px;
    }

    .customer-orders-table {
        min-width: 0;
    }

    .customer-orders-table thead,
    .customer-orders-table
        tbody
        > tr
        > td:not(.order-table__mobile-cell) {
        display: none;
    }

    .customer-orders-table,
    .customer-orders-table tbody,
    .customer-orders-table tr,
    .customer-orders-table .order-table__mobile-cell {
        display: block;
        width: 100%;
    }

    .customer-orders-table .order-table-row {
        margin-bottom: 12px;
        border: 0;
    }

    .customer-orders-table .order-table__mobile-cell {
        padding: 0;
        border: 0;
    }

    .customer-orders-table .order-mobile-card {
        width: 100%;
    }

    .customer-orders-table .order-mobile-card__description {
        display: -webkit-box;
        overflow: hidden;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 3;
        line-clamp: 3;
    }

    .customer-orders-empty {
        padding: 26px 18px;
    }
}





/* ************************ */
/* KONTROLNA TABLA          */
/* ************************ */

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
    gap: 24px;
}

.dashboard-panel {
    min-width: 0;
    overflow: hidden;
    background: var(--surface, #ffffff);
    border: 1px solid var(--border, #e2e8f0);
    border-radius: 16px;
    box-shadow: var(--shadow-sm, 0 8px 24px rgba(15, 23, 42, 0.06));
}

.dashboard-panel__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 22px 22px 18px;
    border-bottom: 1px solid var(--border, #e2e8f0);
}

.dashboard-panel__header h2,
.dashboard-panel__header p {
    margin: 0;
}

.dashboard-panel__header h2 {
    margin-top: 3px;
    font-size: 1.2rem;
}

.dashboard-panel__header p:not(.dashboard-panel__eyebrow) {
    margin-top: 6px;
    color: var(--text-muted, #64748b);
    font-size: 0.88rem;
}

.dashboard-panel__eyebrow {
    color: var(--primary, #2563eb);
    font-size: 0.73rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.dashboard-panel__count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    min-width: 38px;
    min-height: 38px;
    padding: 5px 10px;
    color: var(--primary, #2563eb);
    background: var(--primary-soft, #eff6ff);
    border-radius: 999px;
    font-weight: 800;
}

.dashboard-slots-list,
.dashboard-orders-list {
    padding: 16px;
}

.dashboard-slots-list {
    display: grid;
    gap: 12px;
}

.dashboard-panel__footer-link {
    display: block;
    padding: 15px 22px;
    color: var(--primary, #2563eb);
    border-top: 1px solid var(--border, #e2e8f0);
    font-size: 0.9rem;
    font-weight: 700;
    text-align: center;
    text-decoration: none;
}

.dashboard-panel__footer-link:hover {
    background: var(--surface-muted, #f8fafc);
}

.dashboard-empty-state {
    padding: 34px 22px;
    color: var(--text-muted, #64748b);
    text-align: center;
}

.dashboard-order-row {
    display: grid;
    grid-template-columns:
        minmax(110px, 0.8fr)
        minmax(130px, 1.15fr)
        minmax(120px, 1fr)
        auto;
    align-items: center;
    gap: 14px;
    padding: 14px 6px;
    border-bottom: 1px solid var(--border, #e2e8f0);
}

.dashboard-order-row:last-child {
    border-bottom: 0;
}

.dashboard-order-row--heading {
    padding-top: 2px;
    padding-bottom: 10px;
    color: var(--text-muted, #64748b);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.dashboard-order-row__order,
.dashboard-order-row__info {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.dashboard-order-row__order strong {
    color: var(--text, #0f172a);
}

.dashboard-order-row__order span,
.dashboard-order-row__info small {
    overflow: hidden;
    color: var(--text-muted, #64748b);
    font-size: 0.78rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dashboard-order-row__info a,
.dashboard-order-row__info strong {
    overflow: hidden;
    color: var(--text, #0f172a);
    font-size: 0.9rem;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dashboard-order-row__info a {
    text-decoration: none;
}

.dashboard-order-row__info a:hover {
    color: var(--primary, #2563eb);
}

.dashboard-order-row__label {
    display: none;
}

.dashboard-order-row__button {
    white-space: nowrap;
}

@media (max-width: 1180px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 680px) {
    .dashboard-grid {
        gap: 18px;
    }

    .dashboard-panel__header {
        padding: 18px 16px 15px;
    }

    .dashboard-slots-list,
    .dashboard-orders-list {
        padding: 12px;
    }

    .dashboard-order-row--heading {
        display: none;
    }

    .dashboard-order-row {  
        grid-template-columns: 1fr auto;
        gap: 13px 12px;
        padding: 15px 4px;
    }

    .dashboard-order-row__order {
        grid-column: 1 / 2;
    }

    .dashboard-order-row__info {
        grid-column: 1 / -1;
    }

    .dashboard-order-row__button {
        grid-column: 2 / 3;
        grid-row: 1;
        align-self: center;
    }

    .dashboard-order-row__label {
        display: block;
        color: var(--text-muted, #64748b);
        font-size: 0.7rem;
        font-weight: 800;
        letter-spacing: 0.04em;
        text-transform: uppercase;
    }

    .dashboard-panel__footer-link {
        padding: 14px 16px;
    }
}


@media (max-width: 680px) {
    .topbar__actions .button span:not(.button__icon) {
        display: block !important;
    }
    
    .topbar__actions .button {
        width: fit-content !important;
        padding-left: 10px !important;
        padding-right: 10px !important;
    }
    
    .topbar__actions .button span {
        font-size: 12px !important;
    }
}