:root {
  --white: #f3f4f6;
  --white2: #ffffff;
  --white3: #f0f9fd;
  --light-blue: #c3cfe5;
  --light-blue2: #04cdfd;
  --light-blue3: #b0d8ef;
  --blue: #68b7e6;
  --dark-blue: #0021a7;
  --black: black;
  --grey: #333;
}


body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: var(--white);
}

/* Scrollbar width */
::-webkit-scrollbar {
  width: 12px;
  height: 12px;
}

/* Track (background) */
::-webkit-scrollbar-track {
  background: var(--light-blue);
  /* track color */
  border-radius: 8px;
}

/* Handle (the draggable part) */
::-webkit-scrollbar-thumb {
  background-color: var(--blue);
  /* blue handle */
  border-radius: 8px;
  border: 3px solid var(--light-blue);
  /* space around handle */
}

/* Hover effect for handle */
::-webkit-scrollbar-thumb:hover {
  background-color: var(--light-blue2);
}


/* Fade animations */
.fade-enter {
  opacity: 0;
  transform: translateY(10px);
}

.fade-enter-active {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.fade-exit {
  opacity: 1;
  transform: translateY(0);
}

.fade-exit-active {
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.layout {
  display: flex;
  height: 100vh;
}

main {
  flex: 1;
  padding: 24px;
  overflow-y: auto;
}

main {
  padding: 24px;
}


h1 {
  font-size: 1.5rem;
  font-weight: bold;
  margin-bottom: 16px;
}

h2 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 16px;
}

@media (max-width: 1023px) {
  h1 {
    margin: 0;
  }

  h2 {
    margin-left: 10px;
  }
}

.card {
  background: var(--white2);
  padding: 16px;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  margin-bottom: 20px;
}

input[type="text"],
input[type="number"],
input[type="date"],
input[type="time"],
input[type="email"],
input[type="password"],
input[type="tel"],
input[list],
select,
option,
textarea {
  border-radius: 8px;
  padding: 4px;
  font-size: 14px;
  width: 100%;
  box-sizing: border-box;
  border: 1px solid var(--black);
}


/* Uppercase for all except password */
input:not([type="password"]),
input:not([type="email"]),
select,
option,
textarea {
  text-transform: uppercase;
}

/* Fix password uppercase issue when toggled to text */
.password-wrapper input[type="text"],
input[type="email"] {
  text-transform: none !important;
}

button,
.btn,
.pagination a,
input[type="submit"],
input::file-selector-button {
  background: var(--light-blue3);
  padding: 6px 12px;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  transition: background 0.2s;
  text-decoration: none;
  color: var(--black);
   font-size: 12px;
}

button:hover,
.btn:hover,
.pagination a:hover,
input[type="submit"]:hover,
input[type="file"]::file-selector-button:hover {
  background: var(--light-blue2);
  color: var(--white2);
}

input:required,
select:required,
textarea:required {
  background-color: var(--light-blue);
}


.openModalButton {
  width: max-content;
}

/* FILTER */
.side-by-side-container {
  display: grid;
  grid-template-columns: repeat(3, minmax(350px, 1fr));
  gap: 0px 20px;
  width: 100%;
}

.side-by-side {
  display: flex;
  align-items: center;
  gap: 8px;
}

@media (max-width: 1240px) {
  .side-by-side-container {
    grid-template-columns: repeat(3, minmax(200px, 1fr));
    gap: 0px 10px;
  }
}

/* TABLE */

.tableCont div {
  margin-bottom: 20px;
}

table {
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--white);
}

th,
td {
  padding: 8px 12px;
  border-bottom: 1px solid var(--light-blue3);
}

th {
  background-color: var(--white2);
  cursor: pointer;
  position: relative;
  user-select: none;
}

tr {
  cursor: pointer;
}

tr.selected {
  background-color: var(--light-blue);
}

tr:hover,
tbody tr.group-hover {
  background-color: var(--light-blue);
}

.pagination {
  display: flex;
  gap: 5px
}

.pagination a {
  text-decoration: none;
}

.pagination-controls form {
  margin: 0;
}

/* Arrow indicators */
th a {
  text-decoration: none;
  color: inherit;
  position: relative;
  padding-right: 16px;
  /* space for arrow */
}

th a::after {
  content: '';
  /* default: no arrow */
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  border: 5px solid transparent;
  border-top-color: var(--grey);
  /* arrow color */
  display: inline-block;
}

th a.sorted-asc::after {
  border-bottom: 5px solid var(--grey);
  /* up arrow */
  border-top: none;
}

th a.sorted-desc::after {
  border-top: 5px solid var(--grey);
  /* down arrow */
  border-bottom: none;
}

.table-wrapper {
  overflow-x: auto;
  width: 100%;
}

.table-wrapper table {
  width: max-content;
  min-width: 100%;
  border-collapse: collapse;
}

/* MODAL */

.main-content.modal-open {
  overflow: hidden;
  height: 100vh;
}

/* --- Responsive for SMALL screens --- */
@media (max-width: 1023px) {

  .card {
    padding: 12px;
    overflow-x: auto;
  }

  .side-by-side-container {
    grid-template-columns: 1fr;
    /* single column */
    gap: 0;
    width: 100%;
  }

  .tableCont div {
    margin-bottom: 12px;
  }

  th,
  td {
    padding: 6px 8px;
    font-size: 0.9rem;
  }
}

.short {
  width: 100px;
}

/* Notification Modal Styles */
.notif-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: 9999;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(-20px) scale(0.95);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.notif-modal {
  background: var(--white2);
  border-radius: 12px;
  padding: 30px;
  max-width: 400px;
  width: 90%;
  text-align: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  animation: slideIn 0.3s ease;
}

.notif-modal-icon {
  margin-bottom: 15px;
}

.notif-modal-icon i {
  font-size: 48px;
  color: var(--blue);
}

.notif-modal-content h3 {
  margin: 0 0 10px 0;
  color: var(--grey);
  font-size: 1.4rem;
}

.notif-modal-content p {
  margin: 0;
  color: #666;
  font-size: 1rem;
  line-height: 1.5;
}

.notif-modal-actions {
  margin-top: 25px;
  display: flex;
  gap: 12px;
  justify-content: center;
}

.notif-btn {
  padding: 10px 24px;
  border: none;
  border-radius: 6px;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.notif-btn.primary {
  background: var(--dark-blue);
  color: white;
}

.notif-btn.primary:hover {
  background: #001580;
  transform: translateY(-1px);
}

.notif-btn.secondary {
  background: #e0e0e0;
  color: var(--grey);
}

.notif-btn.secondary:hover {
  background: #d0d0d0;
}