body{
    font-family: sans-serif;
    background-color: #f5f5f5;
    margin: 0px;
}

/* Login style */
.main{
    width: 100%;
    max-width: 500px;
    margin: auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 50px 0px;
    background-color: white;
    border-radius: 20px;
    margin-top: calc(50vh - 250px);
}
.login-logo{
    width: 100%;
    max-width: 200px;
}
.login-title{
    font-size: 16px;
    text-align: center;
    font-weight: 600;
    color: #c4c4c4;
    margin: 20px 0px;
}
.login-form{
    width: 100%;
    max-width: 300px;
    padding: 0px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
.login-form input{
    width: 100%;
    height: 30px;
    border: 1px solid #c4c4c4;
    margin: 10px 0px;
    font-size: 16px;
    color: #343434;
}
.login-form label{
    width: 100%;
    font-size: 16px;
    font-weight: 600;
    color: #343434;
}
.login-form button{
    background-color: #0077ba;
    border: 1px solid #0077ba;
    padding: 15px 25px;
    color: white;
    font-weight: 600;
    font-size: 16px;
    transition: all 0.2s;
    margin-top: 10px;
}
.login-form button:hover{
    background-color: transparent;
    color: #0077ba;
    cursor: pointer;
}

/* Header Admin style */
header{
    width: 250px;
    height: 100%;
    position: fixed;
    top: 0px;
    left: 0px;
    background-color: white;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 0 20px 10px rgba(0, 0, 0, 0.1);
    z-index: 999;
}
.header-content img{
    width: 100%;
    max-width: 150px;
    margin: 30px 0px;
}
.header-content{
    display: flex;
    flex-direction: column;
    align-items: center;
}
.header-content a{
    width: 100%;
    height: 40px;
    text-decoration: none;
    color: #343434;
    font-size: 16px;
    font-weight: 600;
    border-bottom: 1px solid #c4c4c4;
    display: flex;
    align-items: center;
    padding: 0px 20px;
    box-sizing: border-box;
    transition: all 0.2s;
}
.header-content a:hover{
    background-color: #c4c4c4;
}
.logout{
    border-top: 1px solid #c4c4c4;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
}
.logout-text{
    height: 100%;
}
.logout-icon{
    height: 100%;
    display: flex;
    justify-content: right;
    align-items: center;
}
.logout-icon img{
    width: 30px;
    height: 30px;
}

/* Harmonogram style */
.cont{
    width: calc(100% - 290px);
    position: relative;
    top: 0px;
    left: 270px;
    display: flex;
    flex-direction: column;
    align-items: center;
    background-color: white;
    margin: 20px 0px;
    border-radius: 15px;
    box-shadow: 0 0 20px 10px rgba(0, 0, 0, 0.1);
    min-height: calc(100vh - 40px);
}
.cont h2{
    width: 100%;
    text-align: center;
}
.calendar-container { max-width: 100%; overflow-x:auto; transform: rotateX(180deg); margin-bottom: 30px }
.calendar { border-collapse: collapse; width: max-content; margin: 0px 30px; transform: rotateX(180deg); }
.calendar th, .calendar td {
    border: 1px solid #ccc;
    padding: 5px;
    vertical-align: center;
}
.calendar td{
    height: 30px;
    text-align: center;
}
.calendar th {
    background: #eee;
    text-align: center;
    padding: 15px 5px;
}
.hour-cell { width: 45px; background: #fafafa; text-align: right; }
.driver-header { background: #ddd; width: 160px; }
.course {
    padding: 3px;
    margin: 2px 0;
    border-radius: 4px;
    font-size: 0.85em;
}
.controls {
    margin-bottom: 10px;
    display: flex;
    justify-content: center;
}
.controls a{
    text-decoration: none;
    background-color: #0077ba;
    padding: 10px 20px;
    color: white;
    font-weight: 600;
    border-radius: 10px;
    margin: 10px 5px;
    display: block;
    transition: all 0.2s;
    border: 2px solid #0077ba;
}
.controls a:hover{
    background-color: transparent;
    color: #0077ba;
}
.dodaj-btn{
    padding: 10px 20px;
    background-color: #28a745;
    color: white;
    text-decoration: none;
    border-radius: 10px;
    font-weight: 600;
    transition: all 0.2s;
    border: 2px solid #28a745;
    margin-bottom: 20px;
}
.dodaj-btn:hover{
    background-color: transparent;
    color: #28a745;
}
.calendar td{
    height: 70px;
    padding: 0;
}
.calendar td.hour-cell {
    height: 70px;
    min-height: 70px;
    max-height: 70px;
}
.course-block {
    position: absolute;
    left: 2px;
    right: 2px;
    box-sizing: border-box;
    font-size: 12px;
    overflow: hidden;
    border-radius: 4px;
    cursor: default;
    text-decoration: none;
}
.course-content{
    padding: 10px;
}

.resize-handle {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 8px;
    background: #888;
    cursor: ns-resize;
    border-radius: 0 0 4px 4px;
    z-index: 10;
}
.empty-cell{
    width: 160px;
}
.course-content{
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    color: #343434;
    z-index: 9;
    position: relative;
}
.course-content p{
    margin: 0px !important;
}

/* Kontrahenchi style */
.modal {
    display: none;
    position: fixed;
    z-index: 1;
    padding-top: 100px;
    left: 0; top: 0;
    width: 100%; height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.4);
}
.modal-content {
    background-color: #fff;
    margin: auto;
    padding: 20px;
    width: 100%;
    max-width: 400px;
    border-radius: 10px;
}
.modal-content h2{
    width: 100%;
    text-align: center;
    color: #343434;
}
.modal-content form{
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.modal-content form input{
    width: 80%;
    height: 30px;
    font-size: 16px;
    color: #343434;
    box-sizing: border-box;
    margin: 5px 0px;
}
.modal-content form select{
    width: 80%;
    height: 30px;
    font-size: 16px;
    color: #343434;
    margin: 5px 0px;
}
.modal-content form button{
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px 25px;
    background-color: #0077ba;
    color: white;
    font-weight: 600;
    border-radius: 10px;
    border: 2px solid #0077ba;
    transition: all .2s;
    cursor: pointer;
    margin: 20px 0px;
}
.modal-content form button:hover{
    background-color: transparent;
    color: #0077ba;
}
.close {
    color: #aaa;
    float: right;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
}
.table-podstrony{
    width: calc(100% - 40px);
    border-collapse: collapse;
}
.table-podstrony th, .table-podstrony td{
    border-bottom: 1px solid #c4c4c4;
    text-align: center;
    padding: 15px 0px;
}
.title-podstrony-div{
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: calc(100% - 40px);
    margin: 20px 0px;
}
.title-podstrony-div button{
    display: flex;
    justify-content: center;
    align-items: center;
    height: 50px;
    background-color: #0077ba;
    color: white;
    font-weight: 600;
    border-radius: 10px;
    border: 2px solid #0077ba;
    transition: all .2s;
    cursor: pointer;
}
.title-podstrony-div button::before{
    content: "";
    display: block;
    width: 20px;
    height: 20px;
    background-image: url("https://wobetms.eu/img/add.png");
    background-size: cover;
    margin-right: 10px;
}
.title-podstrony-div button:hover{
    background-color: transparent;
    color: #0077ba;
}
.title-podstrony-div button:hover::before{
    background-image: url("https://wobetms.eu/img/add-blue.png");
}
.title-podstrony-div h1{
    display: flex;
    align-items: center;
    color: #343434;
}
.title-podstrony-div h1 img{
    display: block;
    width: 40px;
    margin-right: 20px;
}
.btn-edit{
    border: 1px solid #0077ba;
    border-radius: 10px;
    padding: 5px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    background-color: transparent;
    margin-right: 10px;
}
.btn-edit img, .btn-delete img{
    width: 20px;
}
.btn-delete{
    border: 1px solid #FF0000;
    border-radius: 10px;
    padding: 5px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}
/* Dodaj kurs style */
.form-section {
    margin-bottom: 30px;
    padding: 15px;
    border: 1px solid #ccc;
    border-radius: 10px;
    background-color: #f9f9f9;
    margin: 20px;
}
.form-section h3 {
    margin-top: 0;
}
.form-group {
    margin-bottom: 15px;
    width: 50%;
    display: flex;
    flex-direction: column;
    padding: 0px 20px;
    box-sizing: border-box;
}
.form-inline {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
}
.form-inline .form-group {
    min-width: 250px;
}
select, input{
    height: 25px;
    border: 1px solid #888;
    border-radius: 5px;
    box-sizing: border-box;
}
textarea{
    max-width: 100%;
    height: 100px;
    max-height: 250px;
    border: 1px solid #888;
    border-radius: 5px;
    box-sizing: border-box;
}
.dodaj-button{
    padding: 10px 40px;
    background-color: #0077ba;
    color: white;
    font-size: 18px;
    font-weight: 500;
    border: 2px solid #0077ba;
    border-radius: 10px;
    margin: auto;
    margin-bottom: 40px;
    transition: all 0.2s;
    display: block;
    cursor: pointer;
}
.dodaj-button:hover{
    color: #0077ba;
    background-color: transparent;
}
.dodaj-button-alt{
    padding: 10px 40px;
    background-color: #FF0000;
    color: white;
    font-size: 18px;
    font-weight: 500;
    border: 2px solid #FF0000;
    border-radius: 10px;
    margin-bottom: 40px;
    transition: all 0.2s;
    display: block;
    cursor: pointer;
}
.dodaj-button-alt:hover{
    color: #FF0000;
    background-color: transparent;
}
#hasloDiv{
    width: 80%;
    display: flex;
    justify-content: center;
}
.btn-page {
    padding: 5px 10px;
    border: 1px solid #ccc;
    background-color: #f8f8f8;
    text-decoration: none;
    border-radius: 5px;
    color: black;
}

.btn-page:hover {
    background-color: #ddd;
}

.btn-page.disabled {
    pointer-events: none;
    opacity: 0.5;
    cursor: default;
    background-color: #eee;
    color: #888;
}
.pagination{
    margin-bottom: 20px;
}
#kursList ul{
    list-style-type: none;
    padding: 0px;
}
.calendar tr.day-end td {
    border-bottom: 4px solid #ccc;
}