@import url("https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap");

:root {
    --bs-primary: #4564e5;
    --soft-blue: #f1f5fb;
    --bg-white: #FFFFFF;
    --bg-secondary: #6d747d;
    --bg-success: #188754;

    --card-color: #ffff;

    --bg-primary-opacity: rgba(69, 100, 229, 0.1);
    --bg-success-opacity: rgba(0, 128, 0, 0.1);
    --bg-red-opacity: rgba(255, 77, 79, 0.1);
    --bg-warning-opacity: rgba(255, 215, 0, 0.1);

    /* Text Color */
    --text-color: #707070;
    --text-color-light: #dee2e6;
    --text-color-white: #fff;
    --text-color-primary: var(--bs-primary);
    --text-color-dark: #212529;
    --text-color-danger: #dd3445;

    /* Border Radius */
    --radius-05: 5px;
    --radius-10: 10px;
    --radius-20: 20px;
    --radius-50: 50px;
    --radius-100: 100px;
    --radius-circle: 200px;

    /* Transisi */
    --tran-02: all 0.2s ease;
    --tran-03: all 0.3s ease;
    --tran-04: all 0.4s ease;
    --tran-05: all 0.5s ease;
}

* {
    margin: 0;
    padding: 0;
    font-family: "Poppins", sans-serif;
}

/* Color */
.bg-primary,
.card-primary {
    background-color: var(--bs-primary) !important;
}
.bg-soft-blue {
    background-color: var(--soft-blue);
}
.border-primary {
    border-color: var(--bs-primary) !important;
}

.text-primary {
    color: var(--bs-primary) !important;
}
.text-color {
    color: var(--text-color) !important;
}

/* Font Size */
h1,
h2,
h3,
h4,
h5,
h6,
span,
p {
    padding: 0;
    margin: 0;
}
h1 {
    font-size: clamp(30px, 3vw, 35px) !important;
}
h2 {
    font-size: clamp(25px, 3vw, 30px) !important;
}
h3 {
    font-size: clamp(20px, 3vw, 25px) !important;
}
h4 {
    font-size: clamp(15px, 3vw, 20px) !important;
}
h5 {
    font-size: clamp(10px, 3vw, 15px) !important;
}
h6 {
    font-size: clamp(5px, 3vw, 10px) !important;
}
p {
    font-size: clamp(7px, 3vw, 12px) !important;
}
.fs-7 {
    font-size: clamp(7px, 3vw, 12px) !important;
}
.fs-8 {
    font-size: clamp(8px, 3vw, 12px) !important;
}
td span {
    font-size: clamp(10px, 3vw, 15px) !important;
}


img {
    max-width: 100%;
}
a {
    text-decoration: none;
}

.cursor-pointer {
    cursor: pointer;
}
.logo {
    display: flex;
    align-items: center;
    gap: 5px;
    color: var(--bs-primary);
    font-weight: 700;
}

.flex-centerbetween {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.form-control:focus,
.form-select:focus {
    box-shadow: none;
    border-color: var(--bs-primary);
}
.form-control,
.form-select,
.btn {
    border-radius: 0.5rem;
    padding: 10px 18px;
}
.btn-sm {
    border-radius: 0.5rem;
    padding: 6px 12px;
    font-weight: 400 !important;
}
.btn {
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.btn-delete {
    width: 30px;
    height: 30px;
    background-color: var(--text-color-danger);
}
.btn-primary {
    background-color: var(--bs-primary);
}
.rounded {
    border-radius: var(--radius-10) !important;
}


/* Navbar */
.navbar {
    z-index: 999;
}
.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
}
.avatar img {
    width: 100%;
    height: 100%;
    border-radius: var(--radius-50);
    object-fit: cover;
    object-position: center;
}
.navbar .navbar-nav .nav-item .nav-link {
    color: var(--text-color);
}
.navbar .navbar-nav .nav-item.dropdown .dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}
.navbar .navbar-nav .nav-item.dropdown .dropdown-item:hover,
.navbar .navbar-nav .nav-item.dropdown .dropdown-item.active {
    background-color: var(--bs-primary);
    color: var(--bg-white);
}
.navbar .navbar-nav .nav-item .nav-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 14px;
}
.navbar .navbar-nav .nav-item .nav-link.active,
.navbar #navbarNav1 .nav-item .nav-link:hover {
    background-color: var(--bs-primary);
    color: var(--bg-white);
}
.nav-pills a {
    color: #4564e5;
}
.nav-pills .active,
.nav-pills a:hover {
    background-color: #4564e5 !important;
    color: var(--bg-white);
}

.offcanvas {
    background-color: var(--bg-white);
    max-width: 300px;
    z-index: 9999 !important;
}
.modal-backdrop.fade.show {
    z-index: 1000 !important;
}
.offcanvas .offcanvas-body ul li {
    padding: 10px;
}
.offcanvas .offcanvas-body ul li a {
    text-decoration: none;
    color: var(--text-color);
    font-size: 18px;
    padding: 0px 15px;
}
.offcanvas .offcanvas-body ul li.active {
    background-color: var(--bs-primary);
}
.offcanvas .offcanvas-body ul li.active>* {
    color: var(--text-color-light);
}
.offcanvas .offcanvas-body ul li:hover {
    background-color: var(--soft-blue);
}


/* Dashboard */
.dashboard .col {
  color: var(--text-color-dark);
}
.dashboard .bg-icon-employee,
.dashboard .bg-icon-position {
  color: var(--bs-primary);
  background-color: var(--bg-primary-opacity) !important;
  border-radius: var(--radius-10);
}
.dashboard .bg-icon-active {
  background-color: var(--bg-success-opacity) !important;
  border-radius: var(--radius-10);
}
.dashboard .bg-icon-inactive {
  background-color: var(--bg-red-opacity) !important;
  border-radius: var(--radius-10);
}
.dashboard .card-active:hover {
  border-color: var(--bg-success);
}
.dashboard .card-inactive:hover {
  border-color: var(--text-color-danger);
}


/* Avatar */
.profile-image {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
}
.profile-image img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
}


/* Card */
.card {
  border-radius: 1rem;
  background-color: var(--card-color);
  border-radius: var(--radius-20);
  border: 1px solid transparent;
  transition: var(--tran-03);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}
.card:hover {
  border-color: var(--bs-primary);
}
.card-not-hover:hover {
  border-color: transparent;
}
.card .card-title {
  font-size: 18px;
}


/* Table */
thead tr th {
    border-color: transparent !important;
}


/* Profile */
section.profile .user-info:hover {
  border-color: transparent;
}
section.profile .logout:hover,
section.profile .employee-delete:hover {
  border-color: var(--text-color-danger);
}
section.profile .user-avatar {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-bottom: 30px;
}
section.profile .user-avatar .avatar {
  width: 100px;
  height: 100px;
}
section.profile .actions .card-body {
  padding: 25px 20px;
}


/* Employees */
.actions .search-box {
  display: flex;
  align-items: center;
  width: fit-content;
  background-color: var(--soft-blue);
  border: 1px solid transparent;
  border-radius: var(--radius-10);
  padding: 10px 15px;
  gap: 4px;
}
@media (max-width: 768px) {
    .actions .search-box {
        width: 100% !important;
    }
    .actions .search-box input {
        width: 100% !important;
    }
}
.actions .search-box input {
  width: clamp(100px, 35vw, 200px);
  border: none !important;
  outline: none !important;
  background-color: transparent !important;
  color: var(--text-color-dark);
}
.actions .search-box i {
  color: var(--text-color);
}
.actions .search-box:focus-within,
.actions .search-box:focus-within i {
  border-color: var(--bs-primary);
  color: var(--bs-primary);
  transition: var(--tran-03);
}

.employee .avatar {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    overflow: hidden;
}
@media (max-width: 768px) {
    .employee .avatar {
        width: 100px;
        height: 100px;
    }
}
.employee .avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    object-position: center;
}


/* Modal */
.modal .modal-dialog .modal-content {
  border-radius: var(--radius-20) !important;
  border-color: transparent !important;
}
#edit-profile .modal-body .user-avatar {
  display: flex;
  justify-content: center;
  align-items: center;
}
#edit-profile .modal-body .user-avatar .avatar {
  width: 90px;
  height: 90px;
}

#edit-profile .modal-content .delete-avatar-btn form button {
  position: absolute;
  z-index: 9999;
  top: 50px;
  right: 0;
  border: none;
  outline: none;
  padding: 10px 20px;
  background-color: var(--soft-blue);
  color: var(--text-color-danger);
  font-weight: 600;
  cursor: pointer !important;
}

/* Toasts */
.toast {
  animation: fadeInOut 1s ease-in-out;
}
@keyframes fadeInOut {
  0% {
    opacity: 0;
    transform: translateX(50px);
  }
  50% {
    opacity: 1;
    transform: translateX(-20px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

@media (max-width: 768px) {
  .toast.show {
    width: max-content !important;
    position: fixed;
    margin: 0;
  }
}

.toast.show {
  width: 400px;
  height: max-content;
  position: fixed;
  right: 0;
  padding: 5px;
  margin: 0px 15px;
  background-color: var(--bg-white);
  display: block;
}
.toast .toast-body {
  border-radius: 0px 0px 10px 10px;
}
