/* *************************************** start mobile ******************************* */

@media (max-width: 1000px) {

  /* Desktop verbergen (had je al) */
  .desktop_only { display: none !important; }
  .td_desktop { display: none !important; }

  /* Mobile tonen */
  .mobile_only, #menuDiv, .td_mobile { display: initial !important; }

  /* *************************************** start header ******************************* */

  #headerContainer {
    float: left;
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
  }

  #header {
    float: left;
    width: 100%;
    height: 70px;
    background-color: #202020;
    position: relative;
  }

  #mainContainer {
    float: left;
    position: absolute;
    top: 70px;      /* gelijk aan header hoogte */
    left: 0;
    width: 100%;
    transition: transform 0.3s ease;
  }

  #impersonationDiv {
    float: left;
    width: 100%;
    padding: 10px 15px;
    box-sizing: border-box;
    background: #ff5500;
    margin-bottom: 15px;
  }

  #main {
    float: left;
    width: 100%;
    padding: 15px;
    box-sizing: border-box;
  }

/* *************************************** start menu  ******************************* */

#navigation {
    position: fixed;
    top: 0;
    left: -250px; /* Initially hidden off-screen */
    width: 250px;
    height: 100vh;
    transition: transform 0.3s ease; /* Smooth shifting */
    background-color: #333; /* Optional: Add a background for clarity */
    padding-top: 125px;
    box-sizing: border-box;
}

#navigation ul {
float: left;
width: 100%;
margin-left: 25px;
list-style-type: none;
}

#navigation ul li {
font-size: 18px;
font-weight: bold;
text-transform: uppercase;
padding: 0 !important;
}

#navigation ul li a {
float: left;
width: 100%;
box-sizing: border-box;
color: #fff;
padding: 10px 0 !important;
text-decoration: none;
}

#navigation ul ul {
float: left;
width: calc(100% - 40px);
margin: 0 0 30px 15px !important;
list-style-type: none;
}

#navigation ul ul li {
font-size: 15px;
font-weight: normal;
text-transform: uppercase;
padding: 0 !important;
}

#navigation ul ul li a {
float: left;
width: 100%;
box-sizing: border-box;
color: #fff;
padding: 5px 0 !important;
text-decoration: none;
}

.shifted #mainContainer {
    transform: translateX(250px); /* Move right */
}

.shifted #navigation {
    transform: translateX(250px); /* Move right */
}

.menu-icon {
  width: 30px;
  height: 30px;
  position: absolute;
  top: 15px;
  left: 15px;
  cursor: pointer;
  box-sizing: border-box;
  z-index: 9999;
}

.bar1, .bar2, .bar3 {
position: absolute;
width: 100%;
height: 3px;
background-color: #fff;
}

.bar1 {
top: 8px;
}

.bar2 {
top: 19px;
}

.bar3 {
top: 30px;
}

.bar1.cross {
    animation: bar1-open 0.5s forwards;
}

.bar2.cross {
    animation: bar2-open 0.5s forwards;
}

.bar3.cross {
    animation: bar3-open 0.5s forwards;
}

.bar1.reverse {
    animation: bar1-close 0.5s forwards;
}

.bar2.reverse {
    animation: bar2-close 0.5s forwards;
}

.bar3.reverse {
    animation: bar3-close 0.5s forwards;
}

@keyframes bar1-open {
    0%   { top: 8px; transform: rotate(0deg); }
    50%  { top: 19px; transform: rotate(0deg); }
    100% { top: 19px; transform: rotate(45deg); }
}

@keyframes bar1-close {
    0%   { top: 19px; transform: rotate(45deg); }
    50%  { top: 19px; transform: rotate(0deg); }
    100% { top: 8px; transform: rotate(0deg); }
}

@keyframes bar2-open {
    0%   { visibility: visible; }
    50% { visibility: hidden; }
    100% { visibility: hidden; }
}

@keyframes bar2-close {
    0%   { visibility: hidden; }
    50% { visibility: visible; }
    100% { visibility: visible; }
}

@keyframes bar3-open {
    0%   { top: 30px; transform: rotate(0deg); }
    50%  { top: 19px; transform: rotate(0deg); }
    100% { top: 19px; transform: rotate(-45deg); }
}

@keyframes bar3-close {
    0%   { top: 19px; transform: rotate(-45deg); }
    50%  { top: 19px; transform: rotate(0deg); }
    100% { top: 30px; transform: rotate(0deg); }
}


/* *************************************** einde menu ******************************* */

  /* Header layout (compact) */
  #headerMid {
    float: left;
    width: calc(100% - 90px);
    padding-left: 90px; /* ruimte voor hamburger */
    box-sizing: border-box;
    text-align: center;
  }

  #headerMid img {
    max-width: 110px;
    height: auto;
    margin-top: 12px;
  }

  #headerRight {
    float: left;
    width: 90px;
  }

  #headerRight ul {
    float: right;
    list-style-type: none;
    margin: 22px 12px 0 0;
    padding: 0;
  }

  #headerRight li {
    float: left;
    width: 22px;
    margin-right: 10px;
  }

  #headerRight li img {
    width: 100%;
    height: auto;
  }

  #headerRight li:last-child {
    margin-right: 0;
  }

  #content {
    float: left;
    width: 100%;
  }

  .td_settings img {
    vertical-align: middle;
    margin-right: 5px;
  }

  /* *************************************** start home ******************************* */

  .buttonContainer {
    float: left;
    width: 100%;
  }

  #buttonDiv {
    float: left;
    width: 100%;
    padding: 25px 15px;
    box-sizing: border-box;
    display: grid;
    grid-template-columns: 1fr;  /* 1 kolom mobiel */
    gap: 20px;
  }

  #buttonDiv a {
    padding: 0;
    box-sizing: border-box;
    object-fit: cover;
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
  }

  #buttonDiv a .buttonHome img {
    position: relative;
    width: 100%;
    height: 100%;
  }

  #buttonDiv a:hover .buttonHome img {
    position: relative;
    top: -2%;
    left: -2%;
    width: 104%;
    height: auto;
  }

  #buttonDiv a .buttonHome p {
    color: #fff;
    font-size: 20px;
    font-weight: 900;
    width: 100%;
    text-align: center;
    z-index: 1;
  }

  .textBottom { position: absolute; bottom: 15px; }
  .textTop { position: absolute; top: 15px; }

  /* *************************************** einde home ******************************* */

  /* *************************************** start knoppen ******************************* */

.button {
display: inline-block;
background: #fff;
color: #202020 !important;
padding: 5px 15px;
text-decoration: none !important;
border: 1px solid #202020;
margin: 0 10px 25px 0;
}

.button:hover {
background: #202020;
color: #fff !important;
text-decoration: none !important;
}

.button_neg {
    display: inline-block;
    background: #202020;
    color: #fff !important;
    padding: 5px 15px;
    text-decoration: none !important;
    border: 1px solid #202020;
    margin: 0 10px 25px 0;
    }
    
    .button_neg:hover {
    background: #fff;
    color: #202020 !important;
    text-decoration: none !important;
    }

.button_green {
    display: inline-block;
    background: #008000;
    color: #fff !important;
    padding: 5px 15px;
    text-decoration: none !important;
    border: 1px solid #008000;
    margin: 0 10px 25px 0;
    }
    
.button_green:hover {
    background: #fff;
    color: #008000 !important;
    text-decoration: none !important;
}

    .opdracht_list {
    list-style-type: none !important;
    margin-bottom: 0 !important;
}
  
  /* radio knoppen lijst: wrap prettiger op mobile */
  .opdracht_list {
    list-style-type: none !important;
    margin-bottom: 0 !important;
    padding: 0;
  }

  .opdracht_list li {
    display: inline-block;
    margin: 0 8px 8px 0;
  }

  .opdracht_list label {
    font-size: 14px;
    padding: 7px 12px;
  }

  /* *************************************** einde knoppen ******************************* */

  /* *************************************** start divs ******************************* */

  .div50 {
    float: left;
    width: 100%;
    margin-right: 0;
    margin-bottom: 15px;
  }

  .div100 {
    float: left;
    width: 100%;
  }

  .div600 {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
  }

  /* *************************************** einde divs ******************************* */

  /* *************************************** start forms / inputs ******************************* */

  /* Op mobiel meestal full width */
  select,
  input[type="text"],
  input[type="date"],
  input[type="number"],
  input[type="email"] {
    width: 100%;
    max-width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
  }

select {
  height: 30px !important;
}

  /* *************************************** einde forms / inputs ******************************* */

  /* *************************************** start search orders ******************************* */

  #searchDiv {
    width: 100%;
    padding: 15px;
    box-sizing: border-box;
    display: grid;
    grid-template-columns: 1fr; /* 1 kolom */
    gap: 10px;
    background: #f9f9f9;
    border: 1px solid #ccc;
    border-radius: 8px;
  }

  #searchDivRow {
    display: block;
    white-space: normal;
  }

  #searchDivItem:first-child,
  #searchDivItem:nth-child(2) {
    float: left;
    width: 100%;
  }

  #searchDivItem {
    color: #333;
    font-size: 14px !important;
    margin-bottom: 6px;
  }

  /* *************************************** einde search orders ******************************* */

  /* *************************************** start table orders ******************************* */

  /* Orders tabel horizontaal scrollen op mobile */
.orders-scroll{
  width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  border: 1px solid #ccc;     /* optioneel: geeft ‘container’ gevoel */
  border-radius: 6px;         /* optioneel */
  background: #fff;           /* optioneel */
}

/* Zorg dat de grid echt breder mag zijn dan het scherm */
.orders-scroll .order-container{
  width: max-content;         /* laat 'm zo breed worden als nodig */
  min-width: 980px;           /* kies iets dat past bij je 22 kolommen */
}

/* Kleine optimalisaties voor touch */
.orders-scroll .order-item{
  cursor: default;            /* op mobile vaak fijner (klik blijft via onclick) */
}

.orders-scroll-hint{
  font-size: 13px;
  opacity: 0.7;
  margin: 0 0 8px 0;
}

.order-container {
    display: flex;
    flex-direction: column;
    gap: 5px;
    font-size: 15px !important;
    margin-bottom: 50px;
}

.order-item {
    display: grid;
    /* 1 smalle kolom voor checkbox + 21 kolommen voor data */
    grid-template-columns: 30px repeat(21, minmax(0, 1fr));
    gap: 3px 5px;
    padding: 0;
    border: 1px solid #ccc;
    border-radius: 3px;
    cursor: pointer;
    background-color: #ffffff;
    transition: background-color 0.3s ease;
}

.order-item:hover {
    background-color: #e0e0e0 !important;
    color: #000 !important;
}

.order-item div {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    border-right: 1px solid #ccc;
    padding: 5px;
}

/* Eerste kolom (checkbox) netjes centreren */
.order-item .order-select,
.order-item #cell_select {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* checkbox iets duidelijker klikbaar */
.order-item input[type="checkbox"] {
    cursor: pointer;
}

.order-header {
    font-weight: bold;
    background: #333;
    cursor: default;
    color: #fff;
}

.order-header:hover {
    background-color: #333 !important;
    color: #fff !important;
}

.order-footer {
    font-weight: bold;
    background-color: #e0e0e0 !important;
    cursor: default !important;
    color: #000 !important;
}

.order-footer:hover {
    background-color: #e0e0e0 !important;
    color: #000 !important;
}

.order-header div {
    position: relative;
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
}

/* tooltips kun je laten zoals ze zijn, desnoods background: red weghalen ;) */
.tooltip-container {
    position: relative;
    z-index: 999;
    /* background: red; // debug */
}

.tooltip {
    position: absolute;
    background-color: #333;
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 12px;
    white-space: nowrap;
    pointer-events: none;
    visibility: hiddennnnn;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.order-header div:hover + .tooltip-container .tooltip {
    visibility: visible;
    opacity: 1;
}

/* *************************************** einde table orders ******************************* */

/* ******************************************************************** start drop-zone ********************************************** */

.order-file-dropzone {
    border: 2px dashed #999;
    border-radius: 12px;
    padding: 40px 20px;
    text-align: center;
    background: #fafafa;
    margin-bottom: 20px;
    transition: 0.2s ease;
}
.order-file-dropzone.dragover {
    border-color: #2b6cb0;
    background: #eef6ff;
}
.order-file-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 25px;
}
.order-file-table th,
.order-file-table td {
    padding: 10px;
    border-bottom: 1px solid #ddd;
    text-align: left;
}
.order-file-actions a,
.order-file-actions button {
    margin-right: 8px;
}
.msg-success {
    padding: 12px;
    background: #e6ffed;
    border: 1px solid #b7ebc6;
    color: #1f6f3d;
    margin-bottom: 20px;
}
.msg-error {
    padding: 12px;
    background: #fff1f0;
    border: 1px solid #f5c2c0;
    color: #a61b1b;
    margin-bottom: 20px;
}
.buttonDeleteInline {
    background: #c62828;
    color: #fff;
    border: 0;
    padding: 7px 10px;
    border-radius: 4px;
    cursor: pointer;
}
.buttonDeleteInline:hover {
    background: #a91f1f;
}
.formRow {
    margin-bottom: 15px;
}

/* ******************************************************************** einde drop-zone ********************************************** */

} /* einde mobile */
