/* Modal specific styling */
/* Modal transitions */
.modal-enter {
  opacity: 0;
}
.modal-enter-active {
  opacity: 1;
  transition: opacity 200ms;
}
.modal-exit {
  opacity: 1;
}
.modal-exit-active {
  opacity: 0;
  transition: opacity 200ms;
}

/* Fade out animation for flash messages */
.fadeout {
  animation: fadeout 0.75s forwards;
}

@keyframes fadeout {
  from { opacity: 1; }
  to { opacity: 0; }
}

/* Loading spinner */
.spinner {
  border: 3px solid rgba(0, 0, 0, 0.2);
  border-radius: 50%;
  border-top: 3px solid #3b415e;
  width: 24px;
  height: 24px;
  animation: spin 1s linear infinite;
}

.dark .spinner {
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top: 3px solid #f4f7ff;
  width: 24px;
  height: 24px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Password requirements */
.password-requirements {
    border-radius: 5px;
    background: #eeebe9;
}

.dark .password-requirements {
    border-radius: 5px;
    background: #35404e;
}

/* Message flashing */
.flash-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1050; /* Ensures it's above other elements */
    width: 50%;
    max-width: 600px;
    opacity: 90%;
}
.flash-message {
    margin-bottom: 10px;
}

.custom-alert {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background-color: #4caf50; /* Default green color for success */
    color: white;
    padding: 15px 20px;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    font-size: 16px;
    width: auto;
    max-width: 90%;
    text-align: center;
    transition: opacity 0.5s ease, top 0.5s ease;
}

.custom-alert .close {
    position: absolute;
    top: 0;
    right: 0;
    padding: 10px 15px;
    background: none;
    border: none;
    font-size: 20px;
    line-height: 1;
    color: white;
    opacity: 0.7;
    cursor: pointer;
}

.custom-alert .close:hover {
    opacity: 1;
}

/* Override any Bootstrap styles that might interfere */
.custom-alert.alert-dismissible .close {
    position: absolute;
    top: 0;
    right: 0;
    transform: none;
}

.custom-alert.alert-success {
    background-color: #4caf50;
}

.custom-alert.alert-info {
    background-color: #2196f3;
}

.custom-alert.alert-danger {
    background-color: #f44336;
}

.close-button {
    margin-left: 15px;
    color: white;
    font-weight: bold;
    float: right;
    font-size: 20px;
    cursor: pointer;
}

.close-button:hover {
    color: #ddd;
}

.btn-close {
  box-sizing: content-box;
  width: 1em;
  height: 1em;
  padding: 0.25em 0.25em;
  color: #000;
  background: transparent url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23000'%3e%3cpath d='M.293.293a1 1 0 011.414 0L8 6.586 14.293.293a1 1 0 111.414 1.414L9.414 8l6.293 6.293a1 1 0 01-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 01-1.414-1.414L6.586 8 .293 1.707a1 1 0 010-1.414z'/%3e%3c/svg%3e") center/1em auto no-repeat;
  border: 0;
  border-radius: 0.25rem;
  opacity: 0.5;
}
.btn-close:hover {
    color: #000;
    text-decoration: none;
    opacity: 0.75;
}
.btn-close:focus {
    outline: 0;
    box-shadow: 0 0 0 0.25rem rgba(59, 65, 93, 0.25);
    opacity: 1;
}
.btn-close:disabled, .btn-close.disabled {
    pointer-events: none;
    user-select: none;
    opacity: 0.25;
}

.btn-close-white {
  filter: invert(1) grayscale(100%) brightness(200%); }

/* -------------- */
.alert {
  position: relative;
  padding: 1rem 1rem;
  margin-bottom: 1rem;
  border: 1px solid transparent;
  border-radius: 0.25rem; }

.alert-dismissible {
  padding-right: 3rem; }
  .alert-dismissible .btn-close {
    position: absolute;
    top: 0;
    right: 0;
    z-index: 2;
    padding: 1.25rem 1rem; }

.alert-primary {
  color: #232738;
  background-color: #d8d9df;
  border-color: #c4c6ce; }
  .alert-primary .alert-link {
    color: #1c1f2d; }

.alert-secondary {
  color: #405569;
  background-color: #e1e8ef;
  border-color: #d3dde7; }
  .alert-secondary .alert-link {
    color: #334454; }

.alert-success {
  color: #3e652e;
  background-color: #e1eedb;
  border-color: #d1e5c9; }
  .alert-success .alert-link {
    color: #325125; }

.alert-info {
  color: #055160;
  background-color: #cff4fc;
  border-color: #b6effb; }
  .alert-info .alert-link {
    color: #04414d; }

.alert-warning {
  color: #664d03;
  background-color: #fff3cd;
  border-color: #ffecb5; }
  .alert-warning .alert-link {
    color: #523e02; }

.alert-danger {
  color: #8f3d3d;
  background-color: #fce0e0;
  border-color: #fad1d1; }
  .alert-danger .alert-link {
    color: #723131; }

.alert-light {
  color: #585450;
  background-color: #f8f6f4;
  border-color: #f4f2ef; }
  .alert-light .alert-link {
    color: #464340; }

.alert-dark {
  color: black;
  background-color: #cccccc;
  border-color: #b3b3b3;
}

.alert-dark .alert-link {
    color: black;
}
/* -------------- */
.alert-dismissible .close {
    position: absolute;
    top: 50%;
    right: 1rem;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: 1.5rem;
    line-height: 1;
    color: black;
    opacity: 0.5;
}

.dark .alert-dismissable .close {
    color: white;
}

.alert-dismissible .close:hover {
    color: black;
    opacity: 0.75;
}

.dark .alert-dismissible .close:hover {
    color: white;
    opacity: 0.75;
}

.alert-success {
    background-color: #4caf50;
    color: white;
}

.alert-info {
    background-color: #2196f3;
    color: white;
}

.alert-danger {
    background-color: #f44336;
    color: white;
}

/* Fade-out animation */
@keyframes fadeout {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
        transform: translateY(40px);
    }
}

.fadeout {
    animation: fadeout 1s ease-in forwards;
}

/* Additional tailwind classes */
.error-message {
    color: red;
    font-size: small;
}

.dark .error-message {
    color: #ff6b6b;
    font-size: small;
}

.fixed {
  position: fixed;
}
.p-6{
  padding: 1.5rem;
}
.inset-0 {
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
}
.space-x-3 > :not([hidden]) ~ :not([hidden]) {
  margin-left: 0.75rem;
}
.min-w-\[350\] {
  min-width: 350px;
}

.w-\[30\] {
    width: 30%;
}

.bg-inactive {
  background: rgba(0, 0, 0, 0.6);
}

.z-\[100\] {
  z-index: 100;
}

.mt-3{
  margin-top: 0.75rem;
}