﻿
:root {
    --primary-color: #f57c00;
    --primary-dark: #e65100;
    --primary-darker: #bf360c;
    --primary-light: #ffe0b2;
    --text-color: #212121;
    --background-color: #fff8f0;
    --border-color: #e0e0e0;
    --border-radius: 8px;
    --box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
    --transition-fast: 0.2s;
    /*My def*/
    --side-menu-width: 220px;
    --side-menu-width-mini: 60px;
    --side-menu-width-hidden: 0px;
}


@font-face {
    font-family: 'BusCardFont';
    src: url('/fonts/AldoPC.ttf') format('truetype');
}

.BusCard-Title {
    font-family: 'BusCardFont', serif; /* ili 'PosebanFont' ako je lokalni */
    font-weight: bold;
    font-size: 2rem;
    color: #333;
}

html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

body {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    box-sizing: border-box;
}

*, *::before, *::after {
    box-sizing: inherit;
}

h1:focus {
    outline: none;
}

a, .btn-link {
    color: #0071c1;
}

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.content {
    padding-top: 1.1rem;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}

#blazor-error-ui {
    color-scheme: light only;
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG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1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.loading-progress {
    position: relative;
    display: block;
    width: 8rem;
    height: 8rem;
    margin: 20vh auto 1rem auto;
}

    .loading-progress circle {
        fill: none;
        stroke: #e0e0e0;
        stroke-width: 0.6rem;
        transform-origin: 50% 50%;
        transform: rotate(-90deg);
    }

        .loading-progress circle:last-child {
            stroke: #1b6ec2;
            stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
            transition: stroke-dasharray 0.05s ease-in-out;
        }

.loading-progress-text {
    position: absolute;
    text-align: center;
    font-weight: bold;
    inset: calc(20vh + 3.25rem) 0 auto 0.2rem;
}

    .loading-progress-text:after {
        content: var(--blazor-load-percentage-text, "Loading");
    }

code {
    color: #c02d76;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}


.page-container {
    height: 100vh;
    display: flex;
    flex-direction: column;
}

.top-row {
    position: sticky;
    top: 0;
    height: 50px;
    background-color: #2C2C2C;
    color: #FC861D;
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 8px 10px;
    z-index: 100;
    user-select: none;
    box-sizing: border-box;
    gap: 10px;
}

.top-row button {
    border: 2px solid #ffffff;
    background-color: #2C2C2C;
    color: white;
    padding: 4px;
    font-weight: bold;
    cursor: pointer;
    border-radius: 4px;
    white-space: nowrap;
    transition: background-color 0.3s ease;
}

.top-row button:hover {
    background-color: #ffffff;
    color: #2C2C2C;
}

/* Dugme za sakrivanje/prikaz top row, fiksirano u gornjem desnom uglu viewporta */
#toggleTopRowBtn {
    position: fixed;
    top: 5px;
    right: 10px;
    background-color: #007ACC;
    border: none;
    color: white;
    padding: 8px 12px;
    font-weight: bold;
    cursor: pointer;
    border-radius: 4px;
    user-select: none;
    z-index: 9999;
    white-space: nowrap;
}

#toggleTopRowBtn:hover {
    background-color: #005a9e;
}

.content-area {
    display: flex;
    flex: 1;
    overflow: hidden;
    height: calc(100vh - 40px);
}

.side-menu {
    width: var(--side-menu-width);
    background-color: #1f1f1f;
    border-right: 1px solid #ccc;
    padding: 15px;
    overflow-y: auto;
    min-width: 0;
    transition: width 0.3s ease, padding 0.3s ease;
    position: relative;
    display: flex;
    flex-direction: column;
}

.side-menu.mini {
    width: 60px;
    padding: 15px 5px;
}

.side-menu.hidden {
    width: 0;
    padding: 0;
    border: none;
    overflow: hidden;
}

.side-menu h4 {
    margin-top: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* .side-menu.mini ul,
.side-menu.hidden ul {
    display: none;
}*/

.side-menu li {
    margin-bottom: 8px;
}

.side-menu a {
    text-decoration: none;
    color: #004080;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.side-menu a:hover {
    text-decoration: underline;
}


.sidebar {
    background-color: #1f1f1f; /* tamnosiva pozadina */
    color: #f0f0f0;
    width: 220px;
    padding: 10px;
    height: 100vh;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
}

.sidebar.minimized {
    width: 50px !important;
    align-items: center;
    padding: 10px 0px;
}

.side-menu button {
    background: none;
    border: none;
    color: white;
    font-size: 1.2em;
    margin: 0.5rem;
    cursor: pointer;
}

.side-menu ul {
    list-style: none;
}

.side-menu li {
    margin: 0.3rem 0;
}

.menu-item {
    display: flex;
    align-items: center;
    padding: 0.5rem;
    color: white;
    text-decoration: none;
    cursor: pointer;
}

.menu-item i {
    width: 30px;
    text-align: center;
    font-size: 1.2em;
}

.menu-item span {
    margin-left: 10px;
}


.side-menu .submenu {
    padding-left: 1rem;
}

.side-menu .mini .submenu {
    display: none;
}





.main-content {
    flex: 1;
    overflow-y: auto;
    padding: 4px;
    min-width: 0;
}

.table-container {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid #ccc;
    border-radius: 4px;
    min-width: 0;
}

table {
    border-collapse: collapse;
    width: 100%;
}

thead th {
    position: sticky;
    top: 0;
    background-color: #FFA500;
    color: white;
    padding: 8px;
    border-bottom: 2px solid #004080;
    z-index: 10;
    user-select: none;
}

tbody td {
    padding: 0px;
    border-bottom: 1px solid #ddd;
}


tbody tr:nth-child(even) {
    background-color: #fff3e0; /* svetla pastel narandžasta */
}

tbody tr:nth-child(odd) {
    background-color: #ffeacc; /* još svetlija, nežna krem narandž */
}

tbody tr:hover {
    background-color: #ffdab9; /* blagi pastelni hover */
}

.table-small {
    font-size: 10px;
}

.table-small thead th {
    padding: 6px;
    font-size: 11px;
}

.table-small tbody td {
    padding: 2px 2px;
    line-height: 1;
}

.table-small .selected-row td {
    background-color: lightblue !important;
    padding: 8px !important;
}

/*.table-small tbody tr {
    height: 16px;
}*/

tbody tr.high-row {
    background-color: #fff8e1 !important;
    font-weight: bold;
    box-shadow: inset 0 0 15px rgba(255, 152, 0, 0.3);
}

tbody tr.high-row td {
    padding-top: 8px;
    padding-bottom: 8px;
}

tbody tr.high-row td:first-child {
    border-top-left-radius: 8px;
    border-bottom-left-radius: 8px;
}

tbody tr.high-row td:last-child {
    border-top-right-radius: 8px;
    border-bottom-right-radius: 8px;
}

tbody tr.high-row:hover {
    background-color: #ffdb9a !important;
    box-shadow: inset 0 0 30px rgba(255, 152, 0, 0.7);
    color: #a85a00;
    transition: background-color 0.3s ease, box-shadow 0.3s ease, color 0.3s ease;
}



.sidebar-header {
    display: flex;
    flex-direction: row;
    justify-content: left;
    align-items: center;
    gap: 8px;
    padding: 10px;
    background-color: #2b2b3d;
}

.logo-text {
    font-size: 18px;
    font-weight: bold;
    color: #fca311;
    transition: opacity 0.2s, width 0.2s;
    white-space: nowrap;
    flex-grow: 1;
    display: flex;
    align-items: center;
}

.sidebar.minimized .logo-text {
    opacity: 0;
    width: 0;
    overflow: hidden;
}

.sidebar.minimized .sidebar-header {
    padding: 0;
    gap: 0;
}


.sidebar-content {
    flex-grow: 1;
    overflow-y: auto;
    padding: 10px;
    flex-direction: column;
    text-align: left;
}

.sidebar-footer {
    display: flex;
    flex-direction: row;
    justify-content: center;
    text-align: center;
    padding: 10px;
    background-color: #2b2b3d;
    text-align: center;
}

.side-menu.mini .sidebar-content {
    padding: 0;
}

.side-menu.mini .sidebar-footer {
    display: none;
}

.sidebar-content ul {
    list-style-type: none; /* uklanja tačkice */
    padding: 0;
    margin: 0;
}


.my-icon {
    width: 24px;
    height: 24px;
    color: #fca311; /* narandžasta */
}

    .my-icon:hover {
        color: #ff9c3b;
    }

/*========================================
    Style za menu - hamburger ikonu STAR
=========================================*/

.hamburger {
    width: 30px;
    height: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    cursor: pointer;
}

    .hamburger span {
        display: block;
        height: 4px;
        background-color: #333;
        border-radius: 2px;
    }

    .hamburger span {
        display: block;
        height: 4px;
        background-color: #FC861D; /* ← ovde boja */
        border-radius: 2px;
        transition: background-color 0.2s ease;
    }

    .hamburger:hover span {
        background-color: #FFAE42; /* ← hover boja */
    }

/*========================================
    Style za menu - hamburger ikonu END
=========================================*/



/*========================================
            TimeTable START
=========================================*/

.page-wrapper-tt {
    width: 100%;
    height: calc(100vh - 60px);
    padding: 0;
    box-sizing: border-box;
    background-color: #004328;
}



.button-tt {
    background-color: #004328; /* tvoja boja */
    color: #ffffff;
    border: 2px solid #ffffff;
    padding: 10px 20px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 6px;
    text-wrap: nowrap;
}

    .button-tt:hover {
        background-color: white;
        color: #004328;
    }


.row-title-tt {
    text-align: center;
    font-weight: bold;
    font-size: 1.2rem;
    margin-bottom: 6px;
    color: #ffc214;
    margin-bottom: 6px;
}






.tt-title-lang {
    color: #efc20a;
    font-size: 18px;
}





.button-section-pp-lang {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.button-section-pp-lan-button-row-title {
    text-align: center;
    font-weight: bold;
    font-size: 1.2rem;
    margin-bottom: 6px;
    color: #ffc214;
    margin-bottom: 6px;
}

.button-section-pp-lan-button-row {
    display: flex;
    width: 100%;
    max-width: 600px; /* širina bloka */
    margin-bottom: 12px;
}




.button-section-pp-lan-left {
    display: flex;
    flex: 1;
    justify-content: flex-end;
    padding-right: 10px;
}

.button-section-pp-lan-right {
    display: flex;
    flex: 1;
    justify-content: flex-start;
    padding-left: 10px;
}

.button-section-pp-lang button {
    background-color: #004328; /* tvoja boja */
    color: #ffffff;
    border: 2px solid #ffffff;
    padding: 10px 20px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 6px;
    text-wrap: nowrap;
}

    .button-section-pp-lang button:hover {
        background-color: white;
        color: #004328;
    }

/*========================================
            TimeTable END
=========================================*/




/*PRIKAZA POLAZAK U SMJENI*/
ul.smjenapolazak-list li {
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 0px;
    border-bottom: 1px solid #ccc;
    min-height: 10px;
}

ul.smjenapolazak-list li > div {
    flex-grow: 1;
    padding: 0px;
    min-width: 60px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 11px;
    align-items: center;
    align-content: center;
}

.polazaksmjena-header {
    font-weight: bold;
    background-color: #f0f0f0; /* ili neka boja po izboru */
    color: #000; /* ako ti treba kontrast */
}

.polazakPripremaRasprema {
    font-weight: normal;
    background-color: #D8E4BC;
    color: #000; /* ako ti treba kontrast */
}

.polazakDvokratnaPauza {
    display: flex;
    font-weight: normal;
    background-color: #92D050;
    color: #000; /* ako ti treba kontrast */
    align-items: center;
    justify-content: center;
}


card-table-wrapper {
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 200px); /* ako postoji gornji meni */
    overflow-y: auto;
    position: relative;
}

.card-table-wrapper table {
    font-size: 9px;
    margin-top: 5px;
    width: 100%;
    border-collapse: collapse;
}

.card-header {
    position: sticky;
    top: 0;
    display: grid;
    grid-template-columns: 100px repeat(3, 1fr); /* 1. kolona šira, ostale jednako */
    background-color: #f57c00;
    color: white;
    font-weight: bold;
    padding: 8px 0;
    z-index: 10;
    border-bottom: 2px solid #fff;
    text-align: center;
}

.card-row {
    display: grid;
    grid-template-columns: 60px repeat(3, 1fr);
    background-color: #ffeacc;
    border-radius: 6px;
    border: 1px solid #f57c00;
    margin-bottom: 6px;
    text-align: center;
    /* OVO je bitno */ align-items: stretch; /* ili jednostavno ukloni */
    height: auto; /* osigurava da red raste s sadržajem */

    min-height: 260px;
    overflow: visible;
}

.card-row:nth-child(odd) {
    background-color: #fff3e0;
}

.pruga-label {
    background-color: #f57c00;
    color: white;
    font-weight: bold;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-smjena {
    padding: 8px;
    border: 1px solid #e0e0e0;
    margin: 4px;
    background-color: white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    transition: all 0.2s ease-in-out;
}

    .card-smjena.selected {
        border: 2px solid #f57c00;
        box-shadow: 0 0 10px #f57c00;
        background-color: #fff8e1;
    }


    .card-smjena.empty {
        background-color: #f9f9f9;
        color: #ccc;
        font-style: italic;
        border: 1px dashed #ccc;
        box-shadow: none;
    }

.row-pruga {
    display: flex;
    align-items: stretch;
    margin-bottom: 8px;
    border-radius: 8px;
    transition: background-color 0.2s ease;
}

.card-row:hover {
    background-color: #fff3e0; /* svetla narandžasta pozadina */
    cursor: pointer;
}


.card-smjena table {
    font-size: 11px;
    margin-top: 5px;
    width: 100%;
    border-collapse: collapse;
}

    .card-smjena table thead {
        background-color: #f0f0f0;
        font-weight: bold;
    }

    .card-smjena table th,
    .card-smjena table td {
        border: 1px solid #ccc;
        padding: 1px 6px;
        text-align: center;
        font-size: 10px;
    }

    .card-smjena table tbody tr:nth-child(even) {
        background-color: #fafafa;
    }

.toggle-arrow-btn {
    background: #FFC067;
    border: none;
    padding: 2px;
    font-size: 12px;
    cursor: pointer;
    line-height: 1;
    border-radius: 8px;
    transition: background .2s;
}

    .toggle-arrow-btn:hover {
        background: #FFB347;
    }

    .toggle-arrow-btn:focus {
        outline: none;
        box-shadow: 0 0 0 2px rgba(255,192,103,0.6);
    }




.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-dialog {
    background: white;
    border-radius: 8px;
    max-width: 500px;
    padding: 16px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}

.modal-header h5 {
    margin: 0;
    font-size: 18px;
}

.modal-footer {
    margin-top: 12px;
    text-align: right;
}

.btn-ok {
    padding: 6px 12px;
    border: none;
    background-color: #f57c00;
    color: white;
    border-radius: 4px;
    cursor: pointer;
}


.btn-orange-rounded {
    background-color: #f57c00;
    border: none;
    color: white;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.3s ease;
}

    .btn-orange-rounded:hover {
        background-color: #e65100; /* tamnija narandžasta na hover */
    }

.delete-icon {
    display: inline-block;
    line-height: 1;
    vertical-align: middle;
    cursor: pointer;
}

.day-selector {
    display: flex;
    gap: 8px;
    margin: 12px 0;
}

.day-button {
    padding: 8px 16px;
    border: 1px solid #f57c00;
    background-color: #ffeacc;
    color: #333;
    font-size: 14px;
    font-weight: bold;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s, color 0.3s;
}

    .day-button:hover {
        background-color: #ffdab9;
    }

    .day-button.active {
        background-color: #f57c00;
        color: white;
    }





.orange-select {
    display: block;
    width: 100%;
    padding: 0.075rem 2.25rem 0.075rem 0.75rem;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.5;
    color: #ff8c00;
    background-color: #fff8f0;
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3e%3cpath fill='%23ff8c00' d='M5 6L0 0h10L5 6z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 0.65rem auto;
    background-clip: padding-box;
    border: 1px solid #ff8c00;
    border-radius: 0.375rem;
    appearance: none;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

    .orange-select:focus {
        border-color: #ff6600;
        outline: 0;
        box-shadow: 0 0 0 0.25rem rgba(255, 140, 0, 0.25);
    }


/* za GTFS mape */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
}

.modal {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    min-width: 300px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.preview {
    margin-top: 10px;
    display: inline-block;
}
