@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap");

.settings {
  align-items: stretch;
  display: flex;
  flex-direction: column;
}

.form-group {
  align-items: stretch;
  border-bottom: 1px solid var(--grid-stroke);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 20rem;
  width: 100%;

  &:last-of-type {
    border-bottom: 0;
  }
}

form {
  align-items: stretch;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  justify-content: center;
  max-width: 20rem;
  width: 100%;
}

.auth-container {
  align-items: center;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  justify-content: center;
  min-height: 100dvh;
  width: 100vw;

  .logo {
    height: 7rem;
    object-fit: contain;
  }

  h2 {
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
  }
}


.devise-links {
  align-items: stretch;
  display: flex;
  flex-direction: column;
  gap: var(--spacing-4);

  .link-container {
    align-items: stretch;
    display: flex;
    flex-direction: column;
    font-size: .75rem;
    gap: var(--spacing-1);
    text-align: center;

    a {
      color: var(--link);
      font-size: .75rem;
      transition: all .3s ease;

      &:hover :hover {
        color: var(--link-hover);
      }
    }
  }
}

.access-grant-card {
  display: flex;
  flex-direction: column;
  max-width: 20rem;

  &-title-container {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
  }

  &-title {
    font-size: 1.25rem;
    font-weight: 600;
  }
}

.sidebar-layout {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  width: 100vw;
  height: 100vh;
  overflow: hidden;

  .sidebar-layout__navbar {
    padding: 1rem;
    border-bottom: 1px solid var(--border-border-tertiary);

    .navbar {
      display: flex;
      flex-direction: row;
      justify-content: space-between;
      align-items: center;

      .navbar__logo {
        height: 2rem;
      }
    }
  }

  .sidebar-layout__sidebar {
    display: flex;
    flex-direction: row;
    flex: 1;
    /* Allow the sidebar to grow and shrink properly */
    min-height: 0;

    .sidebar {
      display: flex;
      flex-direction: column;
      justify-content: space-between;
      border-right: 1px solid var(--border-border-tertiary);
      width: 16rem;

      .sidebar__link {
        font-weight: 600;
        padding: 1rem;
        text-decoration: none;
        color: var(--text-text-tertiary);
        transition: var(--transition-all-default);

        &:hover {
          color: var(--text-text-body);
        }

        .sidebar__link--active {
          color: var(--text-text-body);
          border-left: 2px solid var(--background-bg-primary-accent);
        }
      }

      .sidebar__section {
        display: flex;
        flex-direction: column;

        &.sidebar__section--button {
          padding: 1rem;

          .btn {
            text-decoration: none;
            text-overflow: ellipsis;
            white-space: nowrap;
            overflow: hidden;
            display: inline-block;
          }
        }
      }
    }
  }

  .sidebar-layout__content {
    flex-grow: 1;
    padding: 1.5rem;
    overflow-y: auto;
    gap: 2rem;
    display: flex;
    flex-direction: column;
    align-items: stretch;
  }
}

.flash-messages {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-self: center;
  max-width: 20rem;
  width: 100%;
  margin: 0 auto 1rem auto;

  .flash {
    padding: 1rem;
    border-radius: var(--radius-md);
    font-size: 1rem;
    line-height: 120%;
    font-weight: 400;
    color: var(--text-text-body);

    &.flash-notice {
      background-color: var(--background-bg-primary-subtle);
      border: 1px solid var(--border-border-primary);
      color: var(--text-text-body);
    }

    &.flash-alert {
      background-color: var(--background-bg-destructive-disabled);
      border: 1px solid var(--border-border-error);
      color: var(--text-text-error);
    }
  }
}
