/* ===================================
   1. Basisinstellingen & variabelen
=================================== */
:root {
    --logo-color: #000;
    --tab-bg: #ffffff;
    --tab-bg-hover: #c0c0c0;
    --tab-bg-active: #007bff;
    --tab-color: #000;
    --tab-color-active: #fff;


    --primary-color: rgb(0, 123, 255);
    --primary-hover: #0056b3;
    --border-color: #dee2e6;
    --button-border-color: #6ec3ff;
    --primary-hover-light: #cce5ff;
}

body {
    font-family: Arial, sans-serif;
    font-size: 12px;
    margin: 0;
    background-color: #f8f9fa;
    color: #212529;
}

/* ===================================
   2. Layout & algemene containers
=================================== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.mb-4 {
    margin-bottom: 1.5rem;
}

.text-break {
    word-wrap: break-word;
    /* white-space: pre-wrap; */
}


.table-sm td {
    border-color: #eaeaea !important;
}
.table-sm tr:last-child td {
    border-bottom: none;
}


/* ===================================
   3. Navigatiebalk
=================================== */
.navbar {
    background-color: var(--primary-color);
}

.navbar .navbar-brand,
.navbar .nav-link {
    color: #fff;
}

.navbar .nav-link:hover {
    color: #d4d4d4;
}

.nav-link {
    font-size: 0.75rem;
    padding: 4px 8px;
    margin-right: 4px;
    border: 1px solid var(--primary-color) !important;
    border-radius: 4px;
    border-bottom-left-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
    transition: background-color 0.3s, color 0.3s;
}

.nav-link.active {
    background-color: var(--tab-bg-active);
    color: var(--tab-color-active);
    box-shadow: inset 0 -3px 0 0 var(--tab-bg-active);
}

/* ===================================
   4. Tabellen
=================================== */
.table {
    width: 100%;
    border-collapse: collapse;
    background-color: #fff;
}

.table th,
.table td {
    border: 1px solid var(--border-color);
    padding: 0.5rem;
    text-align: left;
}

.table th {
    background-color: #f1f1f1;
    font-weight: 600;
}

.table-striped tbody tr:nth-child(odd) {
    background-color: #f9f9f9;
}

/* ===================================
   5. Knoppen
=================================== */
.btn {
    display: inline-block;
    padding: 0.1rem 0.4rem;
    font-size: 10px;
    font-weight: 400;
    color: #fff;
    background-color: var(--primary-color);
    border: 1px solid var(--button-border-color);
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
}

.btn:hover {
    background-color: var(--primary-hover-light);
    color: black;
    border-color: var(--primary-hover);
}

.btn-secondary {
    background-color: #6c757d;
    border-color: #6c757d;
}

.btn-secondary:hover {
    background-color: #5a6268;
    border-color: #545b62;
}

.gps-link {
    color: #007bff;
    text-decoration: none;
}
.gps-link:hover {
    border: 1px solid var(--button-border-color);
    background-color: #dbedff;
    color: #0056b3;
}

/* ===================================
   6. Formulieren
=================================== */
input,
textarea,
select {
    width: 100%;
    padding: 0.375rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 14px;
}

textarea {
    resize: vertical;
}

.form-select-sm {
    height: 1.5rem;
    padding: 0.1rem 0.5rem 0rem;
    font-size: 11px;
    line-height: 1.5;
    border-radius: 0.25rem;
    
}

/* ===================================
   7. Tabs (originele stijl behouden)
=================================== */
    /* Ensure nav-link is light and consistent */
    .navbar-dark .navbar-nav .nav-link {
        color: rgba(255, 255, 255, 0.85); /* Slightly faded white */
        transition: color 0.1s ease, background-color 0.3s ease;
        border-radius: 6px; /* Rounded corners */
    }

    /* Hover color */
    .navbar-dark .navbar-nav .nav-link:hover,
    .navbar-dark .navbar-nav .nav-link:focus {
        background-color: transparent;
        color: black;
    }

    /* Active/current page link */
    .navbar-dark .navbar-nav .nav-link.active,
    .navbar-dark .navbar-nav .show > .nav-link {
        color: #ffffff !important;
        background-color: transparent;
    }

    /* Optional: Add subtle background on hover */
    .navbar-dark .navbar-nav .nav-link:hover {
        background-color: var(--primary-hover-light);
        border-radius: 6px;
        color: black;
    }
/* ===================================
   8. Responsive
=================================== */
@media (max-width: 768px) {
    .container {
        padding: 0 10px;
    }

    .table th,
    .table td {
        font-size: 12px;
        padding: 0.4rem;
    }

    .btn {
        font-size: 10px;
        padding: 0.3rem 0.6rem;
    }

    .nav-tabs .nav-link {
        font-size: 0.55rem;
        padding: 2px;
    }
}

/* TEXT-Collapsed */

.collapsed {
  max-height: 20em;
  min-height: 5em;
  overflow: hidden;
  position: relative;
  white-space: normal; /* voorkomt extra witruimte van pre-wrap */
}

.collapsed p {
  margin: 0; /* haalt verticale ruimte weg */
}

.collapsed br {
  line-height: 1.2; /* voorkomt grote verticale gaten */
}

.collapsed::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3em;
  background: linear-gradient(to bottom, transparent, white);
}

.collapsed,
.expanded {
  white-space: normal; /* geen grote gaten */
}

.collapsed p,
.expanded p {
  margin: 0 0 0 0;
}

.collapsed br,
.expanded br {
  line-height: 1.2;
}

.custom-list {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 0;
    background-color: #f8f9fa;
    margin-left: 1rem;
    margin-right: 1rem;
}

.table td {
    border-top: 1px solid #eaeaea;
    padding:0.1rem;
}

.table th {
    padding: 0.1rem;
    text-align: left;
}

.clickable-row {
  transition: background-color 0.2s;
}

.clickable-row:hover td {
  background-color: var(--primary-hover-light);
  color: black;
}
/* TOAST CONTROLLER */
.toast-container {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column-reverse; /* nieuwste boven */
    gap: 0.5rem;
    z-index: 9999;
    pointer-events: none; /* klikbare content eronder niet blokkeren */
}

.toast-message {
    min-width: 250px;
    max-width: 400px;
    padding: 1rem 1.5rem;
    border-radius: 0.5rem;
    color: #fff;
    font-weight: 500;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    opacity: 0;
    transform: translateY(20px);
    animation: slideUpFade 0.5s forwards;
    pointer-events: auto;
}

/* Kleuren per type */
.toast-success { background-color: #28a745; }
.toast-error   { background-color: #dc3545; }
.toast-warning { background-color: #ffc107; color: #000; }
.toast-info    { background-color: #17a2b8; }

/* Animatie */
@keyframes slideUpFade {
    0%   { opacity: 0; transform: translateY(20px); }
    100% { opacity: 1; transform: translateY(0); }
}

h5.logo-text {
  font-size: 1.7rem;
  font-weight: 800;
  letter-spacing: -0.8px;
  margin-left: 12px;
  font-family: 'Segoe UI', 'Roboto', 'Helvetica Neue', sans-serif;

  /* Subtiel metallic of zacht wit-lichtgrijs verloop voor premium look */
  background: linear-gradient(
    to bottom,
    #ffffff,           /* Zuiver wit bovenaan */
    #e6f0ff            /* Zeer licht blauwachtig grijs onderaan */
  );

  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;

  /* Fijne, discrete schaduw voor diepte zonder lawaai */
  text-shadow: 0 1px 2px rgba(0, 20, 40, 0.1);

  transition: all 0.3s ease;
}

.btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.0rem;
    transition: transform 0.1s, color 0.2s;
}

.btn-edit {
    color: #f39c12; /* oranje */
}

.btn-edit:hover {
    color: #d35400;
    transform: scale(1.2);
}

.btn-add {
    color: #27ae60; /* groen */
}

.btn-add:hover {
    color: #2ecc71;
    transform: scale(1.2);
}

.btn-rectify {
    background-color: #dc3545; /* rood */
    color: white;
    border: none;
    padding: 5px 8px;
    border-radius: 4px;
    cursor: pointer;
}
.btn-rectify:hover {
    background-color: #c82333;
}



/* SWAL CHECKLIST SELECT */
.swal-custom-popup {
    font-size: 0.875rem; /* kleiner lettertype */
    max-width: 350px;     /* smaller dan standaard */
}

.swal-custom-title {
    font-size: 1rem;      /* titel iets kleiner */
}

.swal-custom-content {
    font-size: 0.875rem;  /* content kleiner */
}

.swal2-select {
    font-size: 0.875rem;  /* dropdown kleiner */
}

  .swal2-html-container {
    font-size: 0.9rem;
    text-align: left;
  }
  .swal2-input, .swal2-select, .swal2-textarea {
    margin-top: 0.25rem;
    margin-bottom: 0.75rem;
  }
  .swal2-confirm, .swal2-cancel {
    font-size: 0.875rem !important;
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }


/* Boomstructuur styling */
/* Ultra-kleine knoppen voor in de boomstructuur */
.tree-small-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    padding: 0;
    border: 1px solid #adb5bd;
    background-color: white;
    color: #495057;
    border-radius: 4px;
    font-size: 0.7rem;
    line-height: 1;
    text-align: center;
    cursor: pointer;
    margin: 0 1px;
    transition: all 0.2s ease;
}

.tree-small-btn:hover {
    background-color: #007bff;
    color: white;
    border-color: #007bff;
}

.tree-small-btn i {
    font-size: 0.8em;
    margin: 0;
}

/* Zorg dat knoppen niet de regelhoogte beïnvloeden */
.asset-node {
    white-space: nowrap;
    line-height: 1.4;
}

/* Optioneel: hover-tooltip */
.tree-small-btn[title] {
    position: relative;
}

.tree-small-btn[title]:hover::after {
    content: attr(title);
    position: absolute;
    top: -28px;
    left: 50%;
    transform: translateX(-50%);
    background: #000;
    color: #fff;
    font-size: 0.75rem;
    padding: 2px 6px;
    border-radius: 4px;
    white-space: nowrap;
    z-index: 10;
}

