#body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-width: 220px; }
  #body *, #body ::before, #body ::after {
    transition: all 400ms; }
  #body .table thead th {
    border-bottom: 1px;
    background-color: rgba(1, 48, 94, 0.1); }
  #body a, #body #main .btn-table {
    background-color: transparent;
    color: #01305e; }
    #body a:hover, #body a:active, #body #main .btn-table:hover, #body #main .btn-table:active {
      color: #fcb042; }
    #body a.btn-danger, #body #main .btn-table.btn-danger {
      color: var(--danger); }
  @media screen and (max-width: 767.98px) {
    #body div.dataTables_wrapper div.dataTables_filter, #body div.dataTables_wrapper div.dataTables_info, #body div.dataTables_wrapper div.dataTables_length {
      text-align: left; } }
  #body div.dataTables_wrapper div.dataTables_processing > div > div {
    background-color: #fcb042; }
  #body div.dataTables_wrapper table.dataTable.dtr-column > tbody > tr > td.dtr-control:before, #body div.dataTables_wrapper table.dataTable.dtr-column > tbody > tr > th.dtr-control:before, #body div.dataTables_wrapper table.dataTable.dtr-column > tbody > tr > td.control:before, #body div.dataTables_wrapper table.dataTable.dtr-column > tbody > tr > th.control:before {
    color: #01305e;
    content: '\f078';
    font-family: 'Font Awesome 5 Free';
    font-weight: bold; }
  #body div.dataTables_wrapper table.dataTable.dtr-column > tbody > tr.parent td.dtr-control:before, #body div.dataTables_wrapper table.dataTable.dtr-column > tbody > tr.parent th.dtr-control:before, #body div.dataTables_wrapper table.dataTable.dtr-column > tbody > tr.parent td.control:before, #body div.dataTables_wrapper table.dataTable.dtr-column > tbody > tr.parent th.control:before {
    content: '\f077'; }
  #body div.dataTables_wrapper table tbody > tr:last-child > td, #body div.dataTables_wrapper table tbody > tr:last-child td.child {
    border-bottom: 1px solid #dee2e6; }
  #body div.dataTables_wrapper table tbody tr.child td {
    border: 0; }
    #body div.dataTables_wrapper table tbody tr.child td.child > table > tr > td[colspan='2'] .btn ~ .btn {
      margin-left: .5rem; }
  #body div.dataTables_wrapper table tbody tr > td[colspan] {
    padding: 0; }
  #body div.dataTables_wrapper table tbody tr > td.fixed:not([style*='display: none']) ~ td.fixed {
    padding-left: 0; }
  #body > div.DTCR_pointer {
    margin-left: -10px;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 10px 10px 0;
    border-color: #fcb042 transparent transparent;
    background: transparent; }
  #body > table.DTCR_clonedTable {
    opacity: 0; }
  #body h1, #body h4 {
    color: #01305e; }
  #body .btn-primary {
    background-color: #01305e;
    border-color: #01305e;
    color: white; }
    #body .btn-primary:disabled, #body .btn-primary.disabled {
      background-color: rgba(1, 48, 94, 0.9);
      border-color: rgba(1, 48, 94, 0.9);
      color: white; }
    #body .btn-primary:focus, #body .btn-primary.focus {
      box-shadow: 0 0 0 0.2rem rgba(1, 48, 94, 0.4); }
    #body .btn-primary:hover {
      background-color: rgba(1, 48, 94, 0.8);
      border-color: rgba(255, 255, 255, 0.2);
      color: white; }
    #body .btn-primary:not(:disabled):not(.disabled):active, #body .btn-primary:not(:disabled):not(.disabled).active, .show > #body .btn-primary.dropdown-toggle {
      background-color: rgba(1, 48, 94, 0.9);
      border-color: white;
      color: white; }
    #body .btn-primary:not(:disabled):not(.disabled):active:focus, #body .btn-primary:not(:disabled):not(.disabled).active:focus, .show > #body .btn-primary.dropdown-toggle:focus {
      box-shadow: 0 0 0 0.2rem rgba(1, 48, 94, 0.4); }
  #body .btn-secondary {
    background-color: #fcb042;
    border-color: #fcb042;
    color: white; }
    #body .btn-secondary:disabled, #body .btn-secondary.disabled {
      background-color: rgba(252, 176, 66, 0.9);
      border-color: rgba(252, 176, 66, 0.9);
      color: white; }
    #body .btn-secondary:focus, #body .btn-secondary.focus {
      box-shadow: 0 0 0 0.2rem rgba(252, 176, 66, 0.4); }
    #body .btn-secondary:hover {
      background-color: rgba(252, 176, 66, 0.8);
      border-color: rgba(255, 255, 255, 0.2);
      color: white; }
    #body .btn-secondary:not(:disabled):not(.disabled):active, #body .btn-secondary:not(:disabled):not(.disabled).active, .show > #body .btn-secondary.dropdown-toggle {
      background-color: rgba(252, 176, 66, 0.9);
      border-color: white;
      color: white; }
    #body .btn-secondary:not(:disabled):not(.disabled):active:focus, #body .btn-secondary:not(:disabled):not(.disabled).active:focus, .show > #body .btn-secondary.dropdown-toggle:focus {
      box-shadow: 0 0 0 0.2rem rgba(252, 176, 66, 0.4); }
  #body .chart-color-1 {
    color: #01305e; }
  #body .chart-color-2 {
    color: #fcb042; }
  #body .custom-control-input:checked ~ .custom-control-label::before, #body .custom-checkbox .custom-control-input:indeterminate ~ .custom-control-label::before {
    background-color: #01305e;
    border-color: rgba(1, 48, 94, 0.6); }
  #body .custom-control-input:focus ~ .custom-control-label::before {
    box-shadow: 0 0 0 0.2rem rgba(1, 48, 94, 0.4); }
  #body .custom-control-input:active:not(:disabled) ~ .custom-control-label::before {
    background-color: rgba(1, 48, 94, 0.6);
    border-color: rgba(1, 48, 94, 0.1); }
  #body .custom-control-input:disabled:checked ~ .custom-control-label::before {
    background-color: rgba(1, 48, 94, 0.7);
    border-color: rgba(1, 48, 94, 0.1); }
  #body .custom-control-input:focus:not(:checked) ~ .custom-control-label::before {
    border-color: rgba(1, 48, 94, 0.6); }
  #body .custom-select:focus {
    border-color: rgba(1, 48, 94, 0.6);
    box-shadow: 0 0 0 0.2rem rgba(1, 48, 94, 0.4); }
  #body .dropdown.show .dropdown-toggle::after {
    border-top: 0;
    border-bottom: .3em solid; }
  #body .dropdown .dropdown-item:hover, #body .dropdown .dropdown-item:active {
    background-color: rgba(1, 48, 94, 0.1); }
  @media screen and (max-width: 767.98px) {
    #body .dropdown .dropdown-item.nav-link {
      padding-left: 1.2rem; }
      #body .dropdown .dropdown-item.nav-link:hover, #body .dropdown .dropdown-item.nav-link:active {
        background-color: unset; } }
  #body .dropdown .dropdown-menu {
    transition: none; }
  #body .dropdown.nav-item .dropdown-menu {
    flex-basis: 100%; }
    @media screen and (max-width: 767.98px) {
      #body .dropdown.nav-item .dropdown-menu {
        border: none;
        margin: 0;
        padding: 0; } }
  #body .form-control:focus {
    border-color: rgba(1, 48, 94, 0.6);
    box-shadow: 0 0 0 0.2rem rgba(1, 48, 94, 0.4); }
  #body .grid-stack-item-content {
    border: 2px solid #eee; }
  #body .manage-nav {
    padding-bottom: 2rem; }
    #body .manage-nav .nav-link.active {
      background-color: #fcb042;
      color: white; }
  #body .navbar-nav .nav-link {
    padding: .2rem .5rem; }
  #body .pagination .page-item.active .page-link {
    background-color: #01305e;
    border-color: #01305e;
    color: white; }
  #body .pagination .page-item .page-link:focus, #body .pagination .page-item .page-link.focus {
    box-shadow: 0 0 0 0.2rem rgba(1, 48, 94, 0.4); }
  #body .text-primary {
    color: #01305e !important; }
    #body .text-primary:focus, #body .text-primary.focus {
      border-color: rgba(1, 48, 94, 0.6);
      box-shadow: 0 0 0 0.2rem rgba(1, 48, 94, 0.4); }
  #body .text-secondary {
    color: #fcb042 !important; }
    #body .text-secondary:focus, #body .text-secondary.focus {
      border-color: rgba(252, 176, 66, 0.6);
      box-shadow: 0 0 0 0.2rem rgba(252, 176, 66, 0.4); }
  #body .validation-summary-errors ul {
    padding-left: 1rem; }

#cookie, #header {
  background-color: white;
  box-shadow: 0 0.1rem 1rem 0.1rem rgba(0, 0, 0, 0.1); }
  #cookie img, #header img {
    max-height: 3.2rem; }

#main {
  flex: 1 1 auto; }
  #main .form-block {
    background-color: rgba(1, 48, 94, 0.02);
    border: 1px solid rgba(1, 48, 94, 0.05);
    border-radius: .25rem;
    margin-bottom: 1rem; }
    #main .form-block > .form-group:last-child {
      margin-bottom: 0; }
  #main .note-editor.note-frame.card *, #main .note-editor.note-frame.card ::before, #main .note-editor.note-frame.card ::after {
    transition: none; }

/* --- LIGHT MODE ELEGANTE --- */
body, #body {
  background-color: #f4f7f6 !important;
  color: #2c3e50 !important;
}

#cookie, #header {
  background-color: #ffffff !important;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05) !important;
  border-bottom: none !important;
}

#main .form-block {
  background-color: #ffffff !important;
  border: none !important;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
  border-radius: 12px;
  padding: 2rem;
}

/* Typography & Titles */
#body h1, #body h2, #body h3, #body h4, #body h5, #body h6 {
  color: #01305e !important;
  font-weight: 700;
}

/* Inputs and Forms */
.form-control {
  background-color: #f8f9fa !important;
  border: 1px solid #e9ecef !important;
  color: #495057 !important;
  border-radius: 8px !important;
  padding: 0.75rem 1rem;
}

.form-control:focus {
  border-color: #fcb042 !important;
  background-color: #ffffff !important;
  box-shadow: 0 0 0 0.2rem rgba(252, 176, 66, 0.25) !important;
}

/* Custom Checkbox/Radio */
#body .custom-control-label::before {
  background-color: #f8f9fa !important;
  border-color: #ced4da !important;
}

/* Primary and Secondary Buttons */
#body .btn-primary {
  background-color: #01305e !important;
  border-color: #01305e !important;
  border-radius: 8px;
  font-weight: bold;
  padding: 0.6rem 1.5rem;
}
#body .btn-primary:hover {
  background-color: #014182 !important;
  box-shadow: 0 4px 15px rgba(1, 48, 94, 0.3);
}

#body .btn-secondary {
  background-color: #fcb042 !important;
  border-color: #fcb042 !important;
  border-radius: 8px;
  color: #ffffff !important;
  font-weight: bold;
  padding: 0.6rem 1.5rem;
}
#body .btn-secondary:hover {
  background-color: #fca326 !important;
  box-shadow: 0 4px 15px rgba(252, 176, 66, 0.3);
}

/* DataTables and Lists */
#body .table {
  color: #2c3e50 !important;
}
#body .table thead th {
  background-color: rgba(1, 48, 94, 0.05) !important;
  border-bottom: 2px solid #e9ecef !important;
  border-top: none !important;
}
#body .table td, #body .table th {
  border-top: 1px solid #e9ecef !important;
}

/* Header Logo Fix */
#header img {
  filter: none;
}

/* General links */
#body a {
  color: #01305e !important;
  font-weight: 500;
}
#body a:hover {
  color: #fcb042 !important;
  text-decoration: none;
}

/* Modals */
.modal-content {
  background-color: #ffffff !important;
  border: none !important;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}
.modal-header, .modal-footer {
  border-color: #e9ecef !important;
}
.modal-title {
  color: #01305e !important;
}

/* ADMIN SIDEBAR LAYOUT */
@media (min-width: 768px) {
  .admin-sidebar-layout header {
    position: fixed;
    top: 0;
    left: 0;
    width: 250px;
    height: 100vh;
    background-color: #ffffff !important;
    border-right: 1px solid #e9ecef;
    box-shadow: 4px 0 15px rgba(0,0,0,0.03);
    z-index: 1000;
  }
  .admin-sidebar-layout header .navbar {
    flex-direction: column !important;
    align-items: flex-start !important;
    padding: 20px;
  }
  .admin-sidebar-layout header .navbar-collapse {
    width: 100%;
  }
  .admin-sidebar-layout header .navbar-nav {
    flex-direction: column !important;
    width: 100%;
  }
  .admin-sidebar-layout header .nav-item {
    width: 100%;
    margin-bottom: 5px;
  }
  .admin-sidebar-layout #main, .admin-sidebar-layout footer {
    margin-left: 250px;
  }
}
